PDA

View Full Version : $session[sessionurl] versus $session[sessionurl_q]


JamesAB
05-20-2015, 05:09 AM
-------------------------
OOPS! I posted this in the wrong forum.:o
This question is in regard to VB3.
-------------------------

I see that the FORUMHOME template uses both versions of this.

What is the difference between $session[sessionurl] and $session[sessionurl_q] ?

What is the rule for when to use $session[sessionurl] and when to use $session[sessionurl_q] ?

Thanks,
James

cellarius
05-20-2015, 08:03 AM
Usage as follows:

For vB4:
<!-- other URL parameters present - add leading question mark! -->
file.php?{vb:raw session.sessionurl}&x=a

<!-- no other URL parameters present - do not add leading question mark! -->
file.php{vb:raw session.sessionurl_q}

<!-- session hash for forms -->
<input type="hidden" name="s" value="{vb:raw session.sessionhash}" />


For vB3:

<!-- other URL parameters present - add leading question mark! -->
file.php?$session[sessionurl]&x=a

<!-- no other URL parameters present - do not add leading question mark! -->
file.php$session[sessionurl_q]

<!-- session hash for forms -->
<input type="hidden" name="s" value="$session[sessionhash]" />

JamesAB
05-20-2015, 10:49 AM
Thanks for the quick response. That was exactly what I needed to know.