Created
February 8, 2017 02:15
-
-
Save joshfeck/bee2bf7d59be77b363a7054dfd34bf45 to your computer and use it in GitHub Desktop.
Example that shows how to add some headings between ticket selector rows. Requires WordPress + Event Espresso 4.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//* Please do NOT include the opening php tag, except of course if you're starting with a blank file | |
add_action( 'wp_enqueue_scripts', 'my_ee_add_ticket_row_headings', 11 ); | |
function my_ee_add_ticket_row_headings() { | |
wp_add_inline_script( | |
'ticket_selector', | |
'jQuery( document ).ready(function($) { | |
$(".ee-ticket-day-1-conference-only-registration-earlybird") | |
.before( "<tr><td colspan=\'3\'><h3>Registration</h3></td></tr>" ); | |
$(".ee-ticket-additional-welcome-event-ticket-earlybird") | |
.before( "<tr><td colspan=\'3\'><h3>Social Events</h3></td></tr>" ); | |
} );' | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
HI Josh,
Is this the title of the ticket? url slug?
$(".ee-ticket-day-1-conference-only-registration-earlybird")
I'm trying to add row in between my tickets and cant get them to display.
I added the snippet you provided to my functions.php and modified the h3 and slug, but still not working.
Am I missing something?