-
-
Save mircobabini/fc2867b3034f3b73fc25d8efef4f0415 to your computer and use it in GitHub Desktop.
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
function showPayFastNotice(){ | |
jQuery('#pmpro_payfast_before_checkout').show(); | |
} | |
function hidePayFastNotice(){ | |
jQuery('#pmpro_payfast_before_checkout').hide(); | |
} | |
jQuery(document).ready(function() { | |
//detect gateway change | |
jQuery('input[name=gateway]').click(function() { | |
var chosen_gateway = jQuery(this).val(); | |
if(chosen_gateway == 'payfast') { | |
showPayFastNotice(); | |
} else { | |
hidePayFastNotice(); | |
} | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment