Support » Plugin: Events Manager » Issue with #_EVENTPOSTID placeholder

  • I am hoping someone can help me with this. I use a plugin called rtMedia to enable my users to upload photos taken at our events on individual event pages. This is done via a shortcode. Thumbnails of the uploaded images are displayed in a grid format on the event page where the shortcode is used. This is the shortcode I am using in the event single page template:

    [rtmedia_gallery context=event context_id=#_EVENTPOSTID media_type=photo media_title=false privacy=0 uploader=after]

    Now the problem I am having starting within the last few days is that uploaded images are not displaying properly on the event pages. Users are not able to see images that were previously uploaded by others, but if a user uploads an image or images himself, the page then displays the newly uploaded images as well as the previously uploaded images. But if the user refreshes the page, the images disappear again (but again reappear if the user uploads more images).

    I believe the issue has something to do with my use of the #_EVENTPOSTID placeholder for the context_id in the above shortcode. Because the images will appear after the upload process, it seems as if something is off with the timing between when the shortcode runs vs. when the #_EVENTPOSTID is loaded (if that makes sense). Again, this used to work until recently. (I believe there was an update to Events Manager recently.)

    I was able to confirm this by replacing the #_EVENTPOSTID placeholder in the above shortcode with a hard coded numeric value for the context_id. I was then able to upload images and view previously uploaded images with no problems. Given this, I don’t think it’s an issue with the rtMedia plugin.

    I should also mention that we display events as pages (as opposed to posts) as defined in the event settings. Not sure if that makes a difference.

    I am hoping there is a quick fix for this. Otherwise is it possible to download the previous version of Events Manager and see if it fixes the issue?

    Thanks.

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Support angelo_nwl

    (@angelo_nwl)

    not sure if EM placeholder #_EVENTPOSTID will work on other plugins shortcode and it might need custom coding on your part to make this work.

    Plugin Support angelo_nwl

    (@angelo_nwl)

    not sure if EM placeholder #_EVENTPOSTID will work on other plugins shortcode and it might need custom coding on your part to make this work.

    Thanks for the reply. I submitted a support ticket with rtMedia as well. The thing is this was working until as recently as a few days ago. I can’t help but think it has something to do with the latest update to EM version 5.8.1.3. Was anything changed that might have affected placeholders? Would it be possible for me to install the previous version and see if it makes a difference? Unfortunately I don’t have a backup that goes back far enough.

    Plugin Support caimin_nwl

    (@caimin_nwl)

    NetWebLogic Support

    This sounds like it could be connected to an issue we’re currently investigating. I’ve added this thread to the bug report so it’ll be updated when there’s news / a fix.

    Meantime, if you wanted to rollback to a previous of Events Manager, older version can be downloaded here:
    https://wordpress.org/plugins/events-manager/advanced/

    I’d recommend making a backup before rolling back. There shouldn’t be a problem but it’s a good insurance policy.

    Thanks for the info. I tried rolling back to 5.8.1.2, but it didn’t make a difference. I’ll keep my eyes open for an update.

    Update…I went rolled back one further to 5.8.1.1, and that did the trick! I see in the changelog there was a change related to shortcodes and parsing, so I’m guessing that had something to do with it? Anyway, I’ll stick with this version until I hear otherwise. Thanks!

    Plugin Support caimin_nwl

    (@caimin_nwl)

    NetWebLogic Support

    Just to let you know, the issue with placeholders not parsing within shortcodes on the single event page has been reported to the developer team for a fix.

    Great – thanks for the update!

    Plugin Author Marcus

    (@netweblogic)

    unfortunately this bug arose by us trying to fix another bug where users were trying to create shortcodes with formats within it e.g.

    [events_list]#_EVENTNAME<br>[/events_list]

    Previously you’d end up with a list containing the name of the same event since #_EVENTNAME was parsed before the shortcode. 5.8.1.2 ‘fixed’ this by parsing shortcodes first, but inadvertedly created this bug you’re reporting since any arguments are not parsed yet.

    We’re going to revert this in the next update. However, since we’re in a bit of a limbo with timezone integration it may be a few more weeks between the next update, so the short-term solution would be to manually edit and comment out or remove this line on /events-manager/classes/em-events.php (line 1710):

    $format = do_shortcode($format); //parse shortcode first, so that formats within shortcodes are parsed properly

    Sorry for the inconvenience! We’ll also be putting this out on the next dev update too, so if you’re up for experimenting with our new timezone features, we’d love to get more people trying it out.

    Thanks Marcus! I was planning on sticking with version 5.8.1.1 for the time being, which works fine for us. I’ll be on the lookout for the next update.

    Hi Marcus…I see version 5.9 was just released, and the release notes mention a fix to a parsing issue. I am still on 5.8.1.1. Do you know if the above issue was fixed in 5.9?

    Plugin Author Marcus

    (@netweblogic)

    Yes, we reverted that ‘fix’ which caused the problem on your shortcode and others that had it that way before the update.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Issue with #_EVENTPOSTID placeholder’ is closed to new replies.