Event Organiser already comes with five shortcodes:
- Displaying list of events:
- Displaying ‘widget’ calendar of events:
- Displaying ‘full’ calendar of events:
- Displaying Google Map of venue:
- Displaying subscribe to events link (via a calendar application.):
However, Event Organiser Pro not only brings you an additional ‘Event Search’ shortcode, but also adds a TinyMCE button for making using shortcodes a lot easier.
ShortCode TinyMCE button
The TinyMCE button added the toolbar allows you to quickly and easily use the event shortcodes.
Clicking the button opens up a dialog window
this gives you an easy to use interface to customise and insert your shortcodes.
Event Search ShortCode
The event search shortcode
[event_search] adds a search form to your page which allows your visitors to search, and optionally filter, your events.
The event search shortcode only has one attribute: filters. This is accepts comma separated list of the filters you want to be available to your visitors. The order in which you specify the filters is the order in which they appear.
Possible filters include
- event_category – a drop-down to filter events by category
- event_category – a drop-down to filter events by venue
- city – a drop-down to filter events by city
- state – a drop-down to filter events by state
- country – a drop-down to filter events by country
- date – two fields with datepickers to filter events by a date range.
The shortcode produces something like:
To create the above search form:
If you wanted to the date filter to appear immediately to the right of the search field
Formatting the output
You can change how the search results appear on the page by copying the template file
search-event-list.php from inside the templates subdirectory of Event Organiser Pro and editing there as desired. See editing the templates for more information.