List of venues

Home Forums Calendar Products Events Calendar PRO List of venues

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #944833
    Gosia
    Participant

    Hello,

    I would like to ask if there is any possibility to create page, where I will display list of venues with map with all venues will be marked. I was trying to make it by some php commands but I did’t get the expected result. 🙂 I will appreciate any help and informatin.

    Regards
    Gosia

    #944958
    George
    Participant

    Hey Gosia!

    This is indeed technically possible, though not something that is included by default with The Events Calendar. So, the complete process of building a Google-Maps page with all the venues populated on the map is something you’ll have to take the reins on, but here at least a few pointers to hopefully help get you started:

    First, the easiest way to get all the venues on your site is to use the function tribe_get_venues() – this function returns a list of venues based on some default settings, but if you want more control of how many venues are retrieved, you could always write a custom WP_Query for the tribe_venue post type. Learn more about WP_Query here.

    Then, once you get the Venues, you should be able to get their locations by using functions like tribe_get_address(), tribe_get_city(), etc. – you can find all of these functions listed in the file at /the-events-calendar/public/template-tags/venue.php.

    The next step would be combining all this data with a Google Map, which is trickier to do and something a bit beyond the scope of the support forums here. But one suggestion is to read through how Events PRO does this for the “Map View” of the plugin – you should be able to copy large chunks of the code from there and implement things into a custom page template after some experimentation.

    I hope this helps!
    Cheers

    #945026
    Gosia
    Participant

    Hello George,

    thank you very much for your answer. With such a great clues I will try to archive my goal.

    Best Regards!
    Gosia

    #945171
    George
    Participant

    Glad to hear it Gosia!

    Best of luck with your project,
    George

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘List of venues’ is closed to new replies.