X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   quick question about if's and userinfo (https://forum.x-cart.com/showthread.php?t=11441)

ddmitche 01-12-2005 11:05 PM

quick question about if's and userinfo
 
This seems really basic, and if anyone has seen a thread that can shed further light please help.(this is categories.tpl)

{if ($userinfo.membership eq "Registered")}
<a href="home.php?cat=254">Download Upgrades
</a>
{else}<a href="../UP_login.php">Looking for upgrades?
</a>{/if}

I am using this code to change what a registered person sees...but it is not working? What am i missing to get this working? I feel like i must be close!

shan 01-13-2005 07:43 AM

Code:

{if $userinfo.membership eq "Registered"}

{else}

{/if}


to see a better list of variables in the debug console edit /smarty.php

change:

Code:

$smarty->debug_tpl="file:debug_templates.tpl";

to:

Code:

$smarty->debug_tpl="file:debug.tpl";

epi 01-17-2005 08:53 AM

Hi,

I am having the same problem. Like the original poster, I would like to use the $userinfo.membership value to give a different greeting, present some other information, et cetera...

But the $userinfo variable is not always set. It is only set when user is logging in, or on his cart/profile pages.

Is there a change we can make so that the $userinfo variable is assigned as often as possible, so we can use the information from $userinfo in the layout?

Cheers!
epi


All times are GMT -8. The time now is 06:44 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.