Created
November 1, 2021 17:01
-
-
Save kallookoo/de35ef6009e692ad46f30b8186441237 to your computer and use it in GitHub Desktop.
jet engine - example hook for redirect with query args
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
add_filter( | |
'jet-engine-booking/filter/hook_name', | |
function ( $result, $data, $form, $notifications ) { | |
if ( $result ) { | |
$data = array_filter( $data ); | |
$page = home_url(); | |
wp_redirect( add_query_arg( $data, $page ) ); | |
exit; | |
} | |
}, | |
10, | |
4 | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment