Compatibility WP Engine Cache?

This topic contains 5 replies, has 2 voices, and was last updated by  AK 6 months, 1 week ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #30880 Reply

    Hi,

    I have been testdriving Events Organiser Pro and I believe it has all the features we need.
    It feels very intuitive !
    We use WP Engine for our hosting, do you know of any known issues with their platform/caching combined with Events Organiser Pro?

    I did a search at this forum and found a few threads, for instance:
    https://wp-event-organiser.com/forums/topic/strange-bug-with-ticket-cap-and-booking-in-pro/

    https://wp-event-organiser.com/forums/topic/issue-with-object-cache-and-wp-engine/

    Thanks!

    AK
    #30883 Reply

    Hi,

    I’ve not tested it with WP Engine myself, but a number of customers have been using it without complaints. With regards to the tickets raised, the second was a bug in some third-party code (not related to the cache at all).

    The first, was related to the cache. In short, you don’t want to cache the event pages which contain the booking forms. This is because the booking form will need to reflect any changes in the availability of the event.

    I hope that helps!

    Stephen Harris
    #30886 Reply

    Thank you,

    So, is it confirmed that the above was related to WP Engine cache?

    I was just chatting with a support agent at WP Engine and they could not find any issues related to WP Engine cache + Event Organiser.

    I also asked if it would be possible to exclude a whole CPT (“Event”) from their cache but unfortunately this is not possible:
    “We would be able to exclude a page, argument or cookie from cache so if it was one of those then for sure we could” …”we would not be able to only exclude the custom post type”

    Excluding specific pages as soon as a “booking form” is available would not an option for us.

    Not sure how to proceed with this, we would love to start working with Event Organiser Pro including booking but need to know that it´s working well at WP Engine ?

    Thanks!

    AK
    #30894 Reply

    Hi again,

    Do you know of a way that could trigger cache exclusion of booking form pages? Are any cookies set here?

    Would it be possible to have a “Book” -button on the event page, that opens up a new smaller window containing only the booking form
    …and exclude that page from cache?

    Is it only the “tickets availability” -functionality that makes booking forms -pages unsuitable for cache?
    …would it be possible to disable the option of setting “max tickets” per event?

    Grateful for your advise on this!

    Thanks!

    AK
    #30904 Reply

    Hi,

    That’s odd, most caching plug-ins allow you to exclude multiple pages using regular expression matching.

    In anycase, it would be possible to have a dedicated booking page (with a few lines of code).

    There is a filter to disable the booking form from appearing on the events page:

    add_filter( 'eventorganiser_pro_get_option_disable_automatic_form', '__return_true' );
    

    Typically you would then add a shortcode to a page, but the shortcode requires you pass the event ID of the event you want to display the booking form for. However, instead of hardcoding the event ID you could create a page template which contained this code:

    $event_id = (int) $_GET['eventId'];
    if($event_id > 0 && get_post_type($event_id) === 'event'){
        echo do_shortcode(sprintf('[event_booking_form event_id=%d]', $event_id));
    }
    

    Then you can link to the booking page:

    yoursite.com/booking-form-page?evenId=<event-id>
    

    That would allow you to exclude a single page from the WP Engine’s cache.

    If you need any help setting this up, just let me know.

    Stephen Harris
    #30908 Reply

    Thank you for looking into this!

    Yes, I agree…think I will contact them again regarding regular expression matching for the event slug.

    I really appreciate the code snippet but would would have preferred the original setup with the form on the actual events page…would it help to exclude page with “#eo-bookings” argument…could there be an appropriate error message if a cached version of the events page tries to book over capacity + reset the form?
    …I guess making it cache safe

    Thanks!

    AK
Viewing 6 posts - 1 through 6 (of 6 total)
Reply To: Compatibility WP Engine Cache?
Your information:




To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four 
    spaces will be stripped off, but all other whitespace
    will be preserved.
    
    Markdown is turned off in code blocks:
     [This is not a link](http://example.com)

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see http://daringfireball.net/projects/markdown/syntax


<a href="" title="" rel=""> <blockquote cite=""> <code> <pre> <em> <strong> <del datetime=""> <ul> <ol start=""> <li> <img src="" border="" alt="" height="" width=""> <p style=""> <span style="">