if cookie, then... in template file {solved}

Christophera

Joined: 2010-03-27
Posts: 19
Posted: Thu, 2010-06-03 01:33

I want to customize one of the template files and add something only if the GALLERYSID cookie is set.

I don't know much about 'smarty' tags, but it looks like they are used exclusively in the templates, not php, which I am more (but not completely) familiar with.

So in smarty, I want to say:

{if GALLERYSID cookie exists}
do this
{/if}

Would someone mind showing me how to do this (assuming it can be done)?

Thank you! Chris

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Thu, 2010-06-03 02:12

Even anon users get a SID, are you trying to detect registered users? {if $user.isRegisteredUser} or admin? {if $user.isAdmin}

-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2

 
Christophera

Joined: 2010-03-27
Posts: 19
Posted: Thu, 2010-06-03 02:57

Ah, got it, thank you very much!

Chris

 
floridave
floridave's picture

Joined: 2003-12-22
Posts: 27300
Posted: Thu, 2010-06-03 04:38