Last active
August 29, 2015 14:07
-
-
Save Pebblo/14c735131cf6c969c24f to your computer and use it in GitHub Desktop.
A fix for a conflict between WP-EMail and Event Espresso. Once the attendee entered their personal information on the registration page, WP-Email would re-direct the user to a share post form, this removes the action for registration pages. Add this to a site specific plugin or your themes functions.php file.
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 if one is already open. | |
function ee_wp_mail_fix() | |
{ | |
global $this_is_a_reg_page; | |
if($this_is_a_reg_page) { | |
remove_action('template_redirect', 'wp_email', 5); | |
} | |
} | |
add_action( 'template_redirect', 'ee_wp_mail_fix', 4 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment