Created
November 30, 2023 17:01
-
-
Save benheu/8d36e739ebebb6c2eedbc7b84a3bd476 to your computer and use it in GitHub Desktop.
Redirect to thank you page WP Wappointment
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 | |
function my_wappo_redirect_appointment_confirmed() | |
{ | |
echo '<script>'; | |
echo "document.addEventListener('wappo_confirmed', function (e) { | |
window.location.replace('https://mysite.com/mythankyoupage'); | |
}, false);"; | |
echo '</script>'; | |
} | |
add_action('wp_print_footer_scripts', 'my_wappo_redirect_appointment_confirmed'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment