Redirect to custom URL after registering from a page with registration form

Redirect to custom URL after registering from a page with registration form

<form action=”<?php echo site_url(‘wp-login.php?action=register’, ‘login_post’) ?>” method=”post”>
<div class=”formrow requiredRow”><label id=”FullName-ariaLabel” for=”txt_FullName”>Full Name</label>
<input class=”required” id=”txt_FullName” title=”Full Name. This is a required field” type=”text” name=”first_name” /></div>

<div class=”formrow requiredRow”><label id=”FullName-ariaLabel” for=”txt_FullName”>Email</label>
<input class=”required” id=”user_email” title=”Full Name. This is a required field” type=”text” name=”user_email” /></div>

<div class=”formrow requiredRow”><label id=”Password-ariaLabel” for=”pwd_Password”>Password</label>
<input class=”required” id=”pwd_Password” title=”Password. This is a required field” type=”password” name=”user_pass” /></div>

<div class=”row”>
<input class=”” id=”user_login” type=”hidden” name=”user_login”/>
<?php do_action(‘register_form’); ?>
<input type=”submit” value=”Submit form” /></div>

</form>

function __my_registration_redirect(){
wp_redirect( ‘/my-page’ );
exit;
}
add_filter( ‘registration_redirect’, ‘__my_registration_redirect’ );

function __my_registration_redirect(){
$url=home_url( ‘/my-page’ );
header(“Location: “. $url);
exit;
}
add_filter( ‘registration_redirect’, ‘__my_registration_redirect’ );

Or


How to redirect a sucessful registration to a page template?

<form action=”<?php echo site_url(‘wp-login.php?action=register’, ‘login_post’) ?>” method=”post”>
<input type=”text” name=”user_login” value=”Username” id=”user_login” class=”input” />
<input type=”text” name=”user_email” value=”E-Mail” id=”user_email” class=”input”  />
<?php do_action(‘register_form’); ?>
<input type=”submit” value=”Register” id=”register” />
<input type=”hidden” name=”redirect_to” value=”/success”/>
<p class=”statement”>A password will be e-mailed to you.</p>
</form>
function __my_registration_redirect()
{
return home_url( ‘/my-page’ );
}
add_filter( ‘registration_redirect’, ‘__my_registration_redirect’ );

Advertisements

3 comments on “Redirect to custom URL after registering from a page with registration form

  1. You actually want your eyelashes tinted by a accredited esthetician for many good reasons. First, it will sting if the product gets in the eyes. An experienced can also work swiftly and carefully to insure that any contact of your merchandise using the eyes is little. Also, a licensed esthetician has access to the ideal tinting products offered. these effective and safe tints take time and effort to the common man or woman to purchase.

  2. Hey all, I just got an HTC One M8 and I am trying to set up google on it but I am getting the error “There was a problem communicating with Google servers. Try again later”. I verify two step verification is off, a factory reset, tried several different networks, made sure date and time was correct and it will not communicate with google at all. I also tried to create a new account on the phone and even if i try and create one with a random user name like *******gmail.com it says that username is taken. It seems to me like the phone just flat out wont connect to google no matter what I try. Like the problem is in the device routing or something. Any thoughts?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s