The Featured Venue widget shows off a specific saved venue in a sidebar and displays events happening at that venue. In this tutorial we'll cover the widget settings, and even toss in some tips and tricks for customizations.
Add the Featured Venue Widget to a Sidebar
The Featured Venue widget is a feature of The Events Calendar PRO, so first make sure that plugin is installed and activated before getting started. With that done, you'll find the widget by heading over to Appearance > Widgets from the WordPress dashboard.
Drag the Events Featured Venue widget to any sidebar area and you're good to go.
Now you can see the widget in all its magnificence on the front end of our website. Here's how that looks:
Featured Venue Widget Settings
There are a few settings available to help you tailor the widget to our needs. Let's go over those.
- Title: This is the heading that sits above the widget. This is empty by default but, in the example above, we changed it to "Featured Venue."
- Venue: This option allows you to select the venue to feature. All the saved venues that can be found in Events > Venues will be listed here and one can be selected per widget.
- Number of events to show: This allows you to specify the maximum number of events to show in the widget at any given time. Three is the default, but the number can be any from one to ten.
- Hide this widget if there are no upcoming events: If this option is selected, then the widget will automatically hide itself if there are no upcoming events for the selected venue. If the option is unselected, then the widget will continue to display, but a notice will display that there are no upcoming events.
Customizing the Featured Venue Widget
Let's say you want to change the content in the widget. We can override the template and modify it there to make some changes with a few steps:
- Make a copy of the template. It is located at /plugins/events-calendar-pro/src/views/pro/widgets/venue-widget.php.
- Make a new folder in the site's theme directory and call it tribe-events.
- Make a new folder in that one called pro.
- Make a new folder in that one called widgets.
- Drop the copied venue-widget.php file in that last folder.
Now that the widget is in your theme directory, you can modify it to suit your needs. For example, you can add the event excerpt to the widget content by placing the following snippet after the event details:
Save that and your widget will now display the event post excerpt beneath the event details. Check out our Themer's Guide for a more comprehensive overview of how to use template overrides.
We hope this overview provides everything you need to bend the Featured Venue widget to your will. The widget is designed to get you up and running right out of the box, but we also wanted to make sure there were plenty of settings and advanced customizations that allow the widget to be more flexible.
Do you have questions that aren't covered here? Please feel free to let us know at our help desk and we'd be happy to help.