How To Prevent Users From Double Booking Events

Have you ever had events that run at the same time, and then had customers book for both events, even though they can’t split themselves in half and see both at the same time?

If so, here is a little trick that Event Espresso maestro himself, Josh, came up with.

First of all you will need to group the events (classes, etc) together in a table. This can be achieved with the table shortcodes from the Custom Files addon.

Adding the following to the page or page template which displays the tables.

<code>&lt;script&gt; jQuery("a.ee_add_item_to_cart").click(function() { jQuery(this).closest(".espresso-table").fadeOut('slow'); })? &lt;/script&gt;</code>

What the code does is hide the table once an item is added to cart, effectively stopping the user from selecting any others from that group.

Check out an example of it here http://jsfiddle.net/joshfeck/Qb5Rr/2/

If the user has Javascript turned off, this will not work.

Need more help?

  • Browse or search for more information on this topic in our support forums. Customers with an active support license can open a support topic and get help from Event Espresso staff.
  • Have an emergency? Purchase a support token and get expedited one-on-one help!
  • Go back to documentation for Event Espresso
Event Espresso - Staging Server