PDA

View Full Version : Redirect on Registration


Sychev_S
03-02-2007, 09:42 PM
Does anybody know how I can automatically redirect someone into their control panel upon registration completetion?

Alright, did it myself.

Find:
eval(standard_error(fetch_error('registration_comp lete', $username, $vbulletin->session->vars['sessionurl'], $vbulletin->options['bburl'] . '/' . $vbulletin->options['forumhome'] . '.php'), '', false));
Comment it out //
Insert below

// Send the User to their picture profile page
$vbulletin->url = "profile.php?do=editprofilepic". $vbulletin->session->vars['sessionurl'];

eval(print_standard_redirect('registration_complet e'));

Aur-Phala.Com
05-02-2007, 02:12 PM
what file did u edit

Mrdby
05-22-2007, 08:25 PM
well?????

da420
05-22-2007, 08:37 PM
register.php...

TriMe
12-01-2008, 03:05 AM
will this work if there is a confirmation email?

davida500
01-28-2009, 06:30 PM
Thank you so much, this is awesome!!!!

ragtek
01-28-2009, 06:32 PM
will this work if there is a confirmation email?

No, because it's in an if condtion
if ($vbulletin->options['verifyemail'])
{
eval(standard_error(fetch_error('registeremail', $username, $email, create_full_url($vbulletin->url . $vbulletin->session->vars['sessionurl_q'])), '', false));
}
else
{
$vbulletin->url = str_replace('"', '', $vbulletin->url);
if (!$vbulletin->url)
{
$vbulletin->url = $vbulletin->options['forumhome'] . '.php' . $vbulletin->session->vars['sessionurl_q'];
}
else
{
$vbulletin->url = iif(strpos($vbulletin->url, 'register.php') !== false, $vbulletin->options['forumhome'] . '.php' . $vbulletin->session->vars['sessionurl_q'], $vbulletin->url);
}

if ($vbulletin->options['moderatenewmembers'])
{
eval(standard_error(fetch_error('moderateuser', $username, $vbulletin->options['forumhome'], $vbulletin->session->vars['sessionurl_q']), '', false));
}
else
{
eval(standard_error(fetch_error('registration_comp lete', $username, $vbulletin->session->vars['sessionurl'], $vbulletin->options['bburl'] . '/' . $vbulletin->options['forumhome'] . '.php'), '', false));
}
}

--------------- Added 1233174777 at 1233174777 ---------------

You could use the register_addmember_complete Hook, then it would work without an fileedit

SVTCobraLTD
07-16-2009, 05:51 PM
Now how would you make it that if a user selects a certain option during registration, it would then send them to a certain page? But if they do not select one, it just does the normal thing?

Dismounted
07-17-2009, 06:08 AM
You just need to check that value, and issue a redirect. The values are found in $vbulletin->GPC.

SVTCobraLTD
07-17-2009, 11:11 AM
I not sure i understand 100%. Can you explain a little more?

Dismounted
07-17-2009, 11:29 AM
Any values that are passed through the vBulletin Input Cleaner will appear in $vbulletin->GPC. You just have to tweak the code posted above to check another value.

Negrosoo
01-01-2010, 01:20 PM
Thank you :P