Append Session ID

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Darksat
Forum Newbie
Posts: 5
Joined: Mon Oct 18, 2004 9:05 am

Append Session ID

Post by Darksat »

Anyone here know how do I apply append_sid() to this view private messages URL in this script.
http://www.aaitechnologies.co.uk/chat/v ... .php?t=164
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

just a thought: call append_sid() with the url.
jonemo
Forum Commoner
Posts: 28
Joined: Wed Feb 09, 2005 1:32 pm
Location: london, uk

Post by jonemo »

somewhere you must have

Code: Select all

$templaet_assign_vars(
'SOMETHING' => 'privmsg.php?folder=inbox'
)
where SOMETHING is something else ;)

replace it with

Code: Select all

$templaet_assign_vars(
'SOMETHING' => append_sid('privmsg.php?folder=inbox')
)
no, i have not read the whole page, but this should roughly be it.
Darksat
Forum Newbie
Posts: 5
Joined: Mon Oct 18, 2004 9:05 am

Post by Darksat »

Ok, where exactly would that be.
its a standard PHPBB install, (well actually it has quite a few mods)

isnt there any way to paste it ito the existing code.
jonemo
Forum Commoner
Posts: 28
Joined: Wed Feb 09, 2005 1:32 pm
Location: london, uk

Post by jonemo »

show us the existing code and we will help you, you just show the template. that's worth nochting. somewhere in the includes/page_header.php in your php installation you will find
'U_PRIVATEMSGS_POPUP' =>
show me whats written around the place where you find this.
Darksat
Forum Newbie
Posts: 5
Joined: Mon Oct 18, 2004 9:05 am

Post by Darksat »

Code: Select all

'U_PRIVATEMSGS' => append_sid('privmsg.'.$phpEx.'?folder=inbox'),
	'U_PRIVATEMSGS_POPUP' => append_sid('privmsg.'.$phpEx.'?mode=newpm'),
	'U_SEARCH' => append_sid('search.'.$phpEx),
Darksat
Forum Newbie
Posts: 5
Joined: Mon Oct 18, 2004 9:05 am

Post by Darksat »

I think I have fixed it.

Will putting

Code: Select all

{U_PRIVATEMSGS}
in this line, eg

Code: Select all

<a class="mainmenu" href=forum/&#123;U_PRIVATEMSGS&#125;/><B>Private Message</B>
append a session id to the link.

I think it will.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

if that is located in the template data, it should be processed, yes.

I would suggest placing quotes around the value of the attribute though.
Post Reply