Support » Plugin: Events Manager » Global events and bookings in multisite environment?

  • Resolved GerZah



    I’m evaluating the possibility of creating a multi-language WordPress site by using a multisite subdomain based environment (with the help of Multilingual Press – Free edition for now).
    I am using empty root blog which is supposed to show more or less just a language selector, plus two child blogs – in this case and for English and German; other languages will follow.

    BuddyPress 2.0.1 is working smoothly (after figuring out the global avatar issue): They show up over both language branches, can interact with each other, all good.

    I got Events Manager 5.5.3 installed. I removed the event related pages from the root blog, but they are present in the child blogs and working well. “Enable global tables mode” is enabled. Still – I can’t figure out how to create global events.

    For the time being, I’m creating events using the WP Admin user. If I create them in the root blog, they are available only in the root blog – which doesn’t work too well, as I don’t have the respective pages there. However, they don’t show up in the child blogs.

    Likewise, if I create events in one the child blogs, they don’t show up in the other one. I can, however, add a “[events_list blog=x]” smartcode to the events page to at least list the other blog’s events.

    But when a user books into an event, his “My Bookings” page shows only the bookings from the child blog he is just visiting. To my knowledge, there’s no “[bookings blog=x]” smartcode that I could add as a workaround.

    So – what am I doing wrong? Is there something that I’m missing to create true global events that will be visible on all child blogs, while hopefully the “My Bookings” page will also show all of them for every user?

    Thanks a lot in advance – any help is highly appreciated!

Viewing 11 replies - 1 through 11 (of 11 total)
  • I’d like to add:

    I can confirm that the events from both child blogs are stored in the wp_em_events table, the respective wp_x_em_events (with x being the id of the child blogs, as defined in wp_blogs) are empty. Same is true for the global wp_em_bookings table, while the wp_x_em_bookings tables are empty.

    The only thing that I can see is: The events in wp_em_events show the blog ID (from wp_blogs) in the blog_id field, which obviously assigns each of the events to one particular blog, i.e. language site.

    Oh-kay. I think I understand know where I am wrong.

    It is possible to display child site events on the main site event list (which needs to be present there). — What’s needed is the other way around, i.e. showing root site events (or otherwise all events from all sites) on the child site event lists.

    And indeed:
    shows all attended events of user “xyz”, while
    show only the attended events from the respective child site.

    However …
    is empty, while
    and (localized URL)
    show the respective local bookings.

    *headscratch* This is all very inconsistent and counterintuitive.

    Plugin Support caimin_nwl



    I’m not sure I follow 100% what you want to do but if you’re sharing events from the main site to the sub-sites Events Manager needs to be operational on the main site.

    This walk-through should help:


    @caimin_nwl Thanks for the pointer. I’ve certainly read and tried to implement what’s said on that documentation page:


    So let me try to put this in other words: I have Events Manager operational on the main site. As a matter of fact, Events Manager is network activated. I have event pages on the main site that are fully functional.

    What I can do right now is: I can see events created in the sub-sites in the main site’s event list. To my understanding, that is what the configuration setting “Display global events on main blog?” achieves.


    However: This is pretty much the opposite of what I would like to achieve. As you put it yourself: It’s about “sharing events from the main site to the sub-sites”.

    What I would like to do is: I would like to create a truly “global event” – on either one of the sub-sites, or perhaps on the main site. But I still would like to see all events on all sites.

    Is there a way to do that?

    Plugin Support caimin_nwl


    Yes, the trick is to use the blog ID in the event shortcode. Something like this:

    [events_list blog=1]

    Thanks. If you look at my OP, you will see that I already do that. But this is more or less just a workaround.

    The problem is not so much in the event list, but in the list of bookings. The “My Bookings” pages in the sub-sites will list only those events that are booked within that particular site. To see bookings from another site, the user will have to visit the respective other sub-site. — I’ve described that in more detail in my 3rd post.

    Plugin Support angelo_nwl


    NetWebLogic Support

    sorry for the confusion but the main issue here is that my-bookings page should only list events books on that particular site wherein right now it also displays other subsites events books ?

    @angelo: No – the other way around! 🙂

    The “My Bookings” shows only bookings from that particular site. I would like it to list bookings from all sites.

    Is this the other way around for you? Why could that be?

    Plugin Support caimin_nwl


    Angelo’s version is the default way My Bookings works in multisite, to make it work in the way you’ve described you’d need to create a custom verion of the My Bookings templates that draws bookings from all blogs.

    Oh-kay. I think I found it.

    (a) There is indeed a [my_bookings] shortcode, as defined in em-shortcode.php. The problem is: It doesn’t seem to be able to accept parameters, like [my_bookings blog=x].

    (b) After a bit of digging, it all boils down to em-person.php and function get_bookings(…)in line 31ff. The crucial comment can be found in line 36:

    //not the main blog, force single blog search

    Well. That leads to line 37:

    $blog_condition = “AND e.blog_id=”.get_current_blog_id();

    So yeah: In contrast to the events list [events_list blog=x], it’s not that easy to actually list my bookings from other sites than the current blog / site. … Truth is: When I comment out line 37, so it does not filter upon get_current_blog_id(), I get exactly what I want: The “My Bookings” page in the sub sites show all bookings from the whole network of sites. Clicking a booking takes the user to the respective subsite.

    Well — darn, now I’ve got a core patch. I don’t like that at all. 🙁

    Plugin Support angelo_nwl


    NetWebLogic Support

    if you can code maybe you can try to hook into em_person_get_bookings filter instead and then do your own filtering and on this way it will be upgrade proof.

    As for where to paste custom code:

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Global events and bookings in multisite environment?’ is closed to new replies.