The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Registration: Passing Source Page Thru Registration Form
When a user completes registration, they are typically greeted with a message that includes a link "Click HERE to return to where you were previously". If vBulletin doesn't actually know where the user came from, that link sends them back to the forum homepage.
If I have an overlay which allows registration on my site without leaving the thread currently being viewed, how do I pass the source page variable through the registration process, so that on the register.php?do=addmember landing page they are given a link back to where they started? |
#2
|
|||
|
|||
You can set $vbulletin->url to the page you want to go to. You could use a plugin on hook register_addmember_complete, for example.
I think you'd also want a plugin on register_start that looks for a specific parameter and sets a variable to be used in the registration template, and then add a hidden field in the form using that variable as the value. That way when the registration form is submitted (or resubmitted after an error), you will have the source page url available to use in the plug mentioned above. I no that's probably not a very clear explanation, but I hope it makes some sense. |
#3
|
|||
|
|||
Thank you kh99. I think I get what you are after.
Do you know what the variable is that I need to get the current page URL on vb3? On vb4, it looks like its "{vb:raw relpath}" --------------- Added [DATE]1352216251[/DATE] at [TIME]1352216251[/TIME] --------------- Maybe "$threadinfo[threadid]" would do it when they access the registration overlay from a showthread.php page. --------------- Added [DATE]1352218072[/DATE] at [TIME]1352218072[/TIME] --------------- Sorry, nevermind. On my custom overlay, I had defined the following url variable statically, once I removed that line, the redirect back to the source URL worked normally. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|