Title: [Plugin: Events Manager] Display Event php code
Last modified: August 20, 2016

---

# [Plugin: Events Manager] Display Event php code

 *  Resolved [fafa-webwau](https://wordpress.org/support/users/fafa-webwau/)
 * (@fafa-webwau)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/)
 * Hi everybody,
 * I’m developping a wordpress theme, and I would like to display some events in
   a specific page.
    I would like to know how to display an event in php code ? 
   After creating some dummy events, I tried to display them using this code:
 *     ```
       if (class_exists('EM_Events')) {
                               echo EM_Events::output( array('limit'=>2,'orderby'=>'name'));
                           }
       ```
   
 * But nothing appears, and when I use “echo ‘aaaa'” in an else condition, it always
   enter in that block.
 * Anybody has an idea ?
 * Thanks
 * [http://wordpress.org/extend/plugins/events-manager/](http://wordpress.org/extend/plugins/events-manager/)

Viewing 6 replies - 1 through 6 (of 6 total)

 *  [agelonwl](https://wordpress.org/support/users/angelonwl/)
 * (@angelonwl)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918329)
 * please see this post for a sample snippet – [http://wordpress.org/support/topic/events-manager-eventslocation-pages-cant-get-sidebar?replies=20](http://wordpress.org/support/topic/events-manager-eventslocation-pages-cant-get-sidebar?replies=20)
 *  Thread Starter [fafa-webwau](https://wordpress.org/support/users/fafa-webwau/)
 * (@fafa-webwau)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918369)
 * Sorry I didn’t precise, but, I’m trying to show the event list. Your post is 
   to show a single event.
 *  [agelonwl](https://wordpress.org/support/users/angelonwl/)
 * (@angelonwl)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918374)
 * you can use shortcode [events_list] with wp do_shortcode.
 * also, see this post – [http://wordpress.org/support/topic/plugin-events-manager-adding-php-to-the-events-list-template?replies=9](http://wordpress.org/support/topic/plugin-events-manager-adding-php-to-the-events-list-template?replies=9)
   there is a snippet for EM_Events::output
 *  Thread Starter [fafa-webwau](https://wordpress.org/support/users/fafa-webwau/)
 * (@fafa-webwau)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918393)
 * When I try this code in my php page template:
    `<?php echo do_shortcode( '[events_list
   limit="10"]' ); ?>` I got this output: “[events_list limit=”10″]”. Is there something
   to do to enable the shortcodes, or maybe a setting I missed in the plugin configuration?
 *  [agelonwl](https://wordpress.org/support/users/angelonwl/)
 * (@angelonwl)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918395)
 * I just tried that `<?php echo do_shortcode( '[events_list limit="10"]' ); ?>`
   on my theme page.php and it works fine?
 *  Thread Starter [fafa-webwau](https://wordpress.org/support/users/fafa-webwau/)
 * (@fafa-webwau)
 * [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918481)
 * My mistake, I installed “Event Manager” instead of “Event**S** Manager” Sorry
   and thanks for your help

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘[Plugin: Events Manager] Display Event php code’ is closed to new replies.

 * ![](https://ps.w.org/events-manager/assets/icon-256x256.png?rev=1039078)
 * [Events Manager - Calendar, Bookings, Tickets, and more!](https://wordpress.org/plugins/events-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/events-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/events-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/events-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-manager/reviews/)

 * 6 replies
 * 2 participants
 * Last reply from: [fafa-webwau](https://wordpress.org/support/users/fafa-webwau/)
 * Last activity: [13 years, 9 months ago](https://wordpress.org/support/topic/plugin-events-manager-display-event-php-code/#post-2918481)
 * Status: resolved