Shortcodes

Event Organiser already comes with five shortcodes:

  1. Displaying list of events: [eo_events]
  2. Displaying ‘widget’ calendar of events: [eo_calendar]
  3. Displaying ‘full’ calendar of events: [eo_fullcalendar]
  4. Displaying Google Map of venue: [eo_venue_map]
  5. Displaying subscribe to events link (via a calendar application.): [eo_subscribe]

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.

shortcode-tinymce-button

Clicking the button opens up a dialog window

shortcode-dialog

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 attributes

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.

Examples

The shortcode produces something like:

event-search-2

To create the above search form:

 [event_search filters="event_category,event_venue,date"]

If you wanted to the date filter to appear immediately to the right of the search field

 [event_search filters="date,event_category,event_venue"]

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.