Skip to content

Instantly share code, notes, and snippets.

@Pebblo
Forked from joshfeck/my_ee_disable_view_cart.php
Created March 5, 2018 12:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Pebblo/f7cdd911c2cc668c7ea0b13dcbab45c7 to your computer and use it in GitHub Desktop.
Save Pebblo/f7cdd911c2cc668c7ea0b13dcbab45c7 to your computer and use it in GitHub Desktop.
Changes the View cart input to '+'. Event Espresso 4 + Multi Event Registration add-on.
<?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_disable_view_cart', 11 );
function my_ee_disable_view_cart() {
wp_add_inline_script(
'espresso_multi_event_registration',
'function changeViewCart(){
jQuery("input[value=\'View Event Cart\']").val("+");
}
jQuery(document).ready(changeViewCart);
jQuery(document).ajaxComplete(changeViewCart);'
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment