Title: Custom PHP Query
Last modified: March 22, 2021

---

# Custom PHP Query

 *  Resolved [leuchtkraft](https://wordpress.org/support/users/leuchtkraft/)
 * (@leuchtkraft)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/custom-php-query/)
 * Hi!
    Is it possible to output events grouped by month without showing filters?
   We want to output the events in an accordion element where the events are filtered
   by selected_datetime. actually, we have created 12 shortcodes and are hiding 
   the filter-form by css. but this is very slow and in Internet Explorer and on
   some mobile devices no events are shown.
 * Or could you please give us an example of a custom php wp_query, in which we 
   could use the order by date and the selected_datetime “option”. this will help
   us a lot.
 * thank you very much!

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

 *  Thread Starter [leuchtkraft](https://wordpress.org/support/users/leuchtkraft/)
 * (@leuchtkraft)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/custom-php-query/#post-14228443)
 * Could anybody help please?
 * we need a short code snippet, how the query of the events works via wp_query 
   with specified date ranges.
 *  [Priya Goenka](https://wordpress.org/support/users/priyagoenka/)
 * (@priyagoenka)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/custom-php-query/#post-14236992)
 * Hi [@leuchtkraft](https://wordpress.org/support/users/leuchtkraft/)
 * You can hide the filters using the shortcode, [events show_filters=”false”]
    
   This will work when you add the selected date time shortcode on the same page.
 * Regards
    Priya
 *  Thread Starter [leuchtkraft](https://wordpress.org/support/users/leuchtkraft/)
 * (@leuchtkraft)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/custom-php-query/#post-14237366)
 * yes i tried following shortcode to display all events in march.
    `[events selected_datetime
   ="01.03.2021,31.03.2021" orderby="event_start_date" show_filters=”false”]`
 * as soon as i add `show_filters="false"` it ignores the date and display all events.
   i think it is because the specified date is passed to the filter and the events
   are output based on the filter. can this be? thats why i wanted to display the
   events via wp_query.
    -  This reply was modified 5 years, 2 months ago by [leuchtkraft](https://wordpress.org/support/users/leuchtkraft/).
 *  [Priya Goenka](https://wordpress.org/support/users/priyagoenka/)
 * (@priyagoenka)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/custom-php-query/#post-14257351)
 * Hi [@leuchtkraft](https://wordpress.org/support/users/leuchtkraft/)
 * Can you please ensure the date format that you are using in this shortcode is
   the same as that of the date picker?
    If yes, please create a support ticket 
   here: [https://support.wp-eventmanager.com/portal/en/home](https://support.wp-eventmanager.com/portal/en/home)
 * Regards,
    Priya

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

The topic ‘Custom PHP Query’ is closed to new replies.

 * ![](https://ps.w.org/wp-event-manager/assets/icon-256x256.png?rev=1622826)
 * [WP Event Manager – Events Calendar, Registrations, Sell Tickets with WooCommerce](https://wordpress.org/plugins/wp-event-manager/)
 * [Support Threads](https://wordpress.org/support/plugin/wp-event-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-event-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-event-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-event-manager/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Priya Goenka](https://wordpress.org/support/users/priyagoenka/)
 * Last activity: [5 years, 2 months ago](https://wordpress.org/support/topic/custom-php-query/#post-14257351)
 * Status: resolved