In this article we going to explain, a hook which can help you to run or fire any action on click of user profile update button.
after doing lots of research we have finally done with one option to add any of the functionality in this Hook which fires or starts execution on update of user information.
// redirect to thank you page add_action( 'profile_update', 'custom_profile_redirect', 12 ); function custom_profile_redirect() { //custom function wp_redirect( trailingslashit("/profile-updated-succesfull") ); exit; }
The above code is the function where you have to paste in the active theme’s functions.php file.
In the above example we have written a small function to redirect once the user click’s on the Update Profile button. If you have any questions please write it in the below comment box.
Happy coding 😉
Add Comment