javascript - WP user profile: redirect to new page on update profile submit -


i've added multitude of custom fields backend user profile, divided sections. each section can updated using regular submit button. have created checkbox after last field when checked, unhides new submit button , hides original submit button. new submit button exact copy of original submit button in user-edit.php file except placed within own div.

my question is, how modify code new submit button still updates profile normal redirects user page of choice? keep in mind don't want redirect effect take place @ times when original submit button clicked there numerous custom fields , user want periodically update before finishing sections.

this current code new submit button (based on original submit button in user-edit.php)

<?php submit_button( is_profile_page ? __('send completed application') : __('send completed application') ); ?> 

try out using wordpress built in function.

<?php submit_button( is_profile_page ? __('send completed application') : __('send completed application') ); wp_redirect( 'http://www.example.com', 301 ); exit; ?> 

Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -