The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Forcing redirect leads to token error
I am currently trying to redirect from page A to page B based if post data sent to page B is incorrect.
Using the method Code:
header('Location: http://www.website.com/pageA.php'); Code:
Your submission could not be processed because a security token was missing. If this occurred unexpectedly, please inform the administrator and describe the action you performed before you received this error. Does anyone have any idea how I can achieve this as the above method seems invalid? |
#2
|
||||
|
||||
wrap it in ob_start(); ob_end_flush(); ?
|
#3
|
|||
|
|||
Tried that as well.
I found that it has to do with the CSRF protection being defined to true on PAGE B. I tried sending the hash and security token in the form as hidden with: Code:
<input type="hidden" name="s" value="$session[sessionhash]" /> <input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" /> --------------- Added [DATE]1334041500[/DATE] at [TIME]1334041500[/TIME] --------------- Sigh, its getting late and I am just not thinking things through. I forgot to alter the values for the change in how vb4 handles the variables. Code:
<input type="hidden" name="s" value="{vb:raw session.sessionhash}" /> <input type="hidden" name="securitytoken" value="{vb:raw bbuserinfo.securitytoken}" /> |
#4
|
||||
|
||||
lol, that will do it. glad you got it resolved. Next time post the code so we can save you the headache
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|