Skip to content

Instantly share code, notes, and snippets.

@lorenzocaum
Last active May 5, 2016 22:08
Show Gist options
  • Save lorenzocaum/f899c0b93fbc282bc1a9 to your computer and use it in GitHub Desktop.
Save lorenzocaum/f899c0b93fbc282bc1a9 to your computer and use it in GitHub Desktop.
How to change the empty event queue messaging in registration checkout for Event Espresso 4

Add the sample code below to your child theme's functions.php file or in a site specific plugin.

<?php
//* Do NOT include the opening php tag

//* Change the empty event queue messaging in Event Espresso 4
add_filter ('FHEE__Single_Page_Checkout__display_spco_reg_form__empty_msg', 'ee_return_to_event_listings_from_empty_event_queue');

function ee_return_to_event_listings_from_empty_event_queue() {
    return 'You need to <a href="http://example.com/events/" title="Return to event listings page">select at least one event</a> before you can proceed with the registration process.';
}