Extensions

Search Extensions

List Venues and Organizers Shortcodes

Sometimes it can be useful to present visitors to your site with a list of all your Venues and Organizers.

Just like individual Events, Venues and Organizers are stored as posts in the database; this makes it really easy to query for them and build up a list.

To help your Venues and Organizers get some attention around your site, we created this handy extension for you.

Once you install and activate the plugin, you will have access to three new shortcodes:

  • [list_organizers]
  • [list_venues]
  • [tec_list_linked_posts post_type="..."]

Simply embed these – including some optional parameters – in a page or post and you’re done!

Attributes

limit

  • The maximum number of Venues or Organizers to return
  • Default: -1

order

  • Post order: "ASC" or “DESC"
  • Default: ASC

orderby

exclude/include

  • Comma-separated list of Venue or Organizer post IDs

author

  • Venue or Organizer author ID or "current_user"

thumb

  • "yes" to include Venue or Organizer thumbnails

details

  • "yes" to include Venue or Organizer details

count

  • "yes" to include count of upcoming events for each Venue or Organizer

hide_empty

  • "yes" to exclude Venues or Organizers without upcoming events

Notes

  • Each Venue and Organizer will link to its own listing page only if you are running The Events Calendar PRO in addition to The Events Calendar. If you are not running PRO, it will output the titles without linking the items.
  • If using this shortcode to output custom linked post types (such as Instructors), you will need to add some custom code to get the “count” and the “hide_empty” shortcode arguments to work.

Example

The shortcode below is an example of a page showing a list of Venues.

Each title is automatically linked to the relevant Venue Page or Organizer Page (if you have PRO activated), and they’re listed alphabetically by default.

[list_venues thumb="yes" count="yes" details="yes" author="current_user" hide_empty="yes"] 

Requirements

  • PHP version 5.6 or newer
  • WordPress version 4.5 or newer
  • The Events Calendar version 4.3 or newer

Changelog

Version 2.1.3

  • July 9, 2019
  • Fix – The shortcode’s “count” argument is now correct, no longer limited by the default ‘posts_per_page’ from tribe_get_events() [119631]

Version 2.1.2

  • November 20, 2018
  • Fix – Added a check to make sure the right type is passed when creating shortcode

Version 2.1.1

  • August 27, 2018
  • Fix – Use our native functions to get the Organizer and Venue names and links so those get filtered and display consistent with the rest of the site. (This means our Make Venue Names Link to the Venue Website URL extension should work with this one.)
  • Tweak – Custom linked post types (other than Organizer and Venue) now link the post title, even without Events Calendar PRO
  • Tweak – Added the tribe_venue_organizer_shortcode_link filter to allow customizing any link of any post type
  • Tweak – Display the excerpt instead of the full post content as the Item Details for all custom linked post types other than Organizer and Venue
  • Tweak – Now requires PHP 5.6+, as do all of our plugins and extensions.

Version 2.1.0

  • March 23, 2018
  • Feature – Registers a new [tec_list_linked_posts] shortcode that can have any linked post type passed to its “post_type” argument, which means this shortcode now supports custom linked post types (see code comments for limitations), such as from https://theeventscalendar.com/knowledgebase/linked-post-types/
  • Tweak – Reworked some filters to fix some not being applied and to pass the $post_id to filters within the loop (for each linked post type post)

Version 2.0.0

  • March 19, 2018
  • Fully rewritten in our Extensions Framework
  • Fix – Listing Organizers now works
  • Fix – No longer links to single Venue or Organizer pages if PRO is not active
  • Feature – Optionally limit the quantity of Venues or Organizers output
  • Feature – Optionally list Venue or Organizer by ID(s)
  • Feature – Optionally exclude Venues or Organizers by ID(s)
  • Feature – Optionally output Venue or Organizer featured image
  • Feature – Optionally output Venue or Organizer count of upcoming events
  • Feature – Optionally hide Venues or Organizers without upcoming events
  • Feature – Optionally sort Venues or Organizers by WP_Query’s order and orderby parameters
  • Feature – Optionally display Venues or Organizers by author

Version 1.0.0

  • April 1, 2015
  • Initial version released as a Knowledgebase plugin.

Download Extension

👋 Heads up! We provide limited support for extensions, but you can still open a ticket over at our Help Desk to report any issues.
Install Instructions