View Single Post
  #22  
Old 10-21-2009, 05:25 AM
  TBone's Avatar 
TBone TBone is offline
 

Advanced Member
  
Join Date: May 2007
Posts: 38
 

Default Re: If statement help - wholesale

If you still want to use the name of the membership instead of the id use this code:

Code:
$userinfo = func_query_first("SELECT A.login,A.firstname,A.lastname,B.membership FROM $sql_tbl[customers] A, $sql_tbl[memberships] B WHERE A.login='$login' and A.membershipid = B.membershipid"); $smarty->assign("userinfo", $userinfo);

and this in your .tpl file:

Code:
{if $userinfo.membership eq "Gold Member"}
__________________
_____________________________________________
www.webcreatives.nl | X-Cart Shops
X-Cart Versions 4.1.x | 4.2.x | 4.3.x | 4.4.x
Parallelweg 124-14, 1948 NN BEVERWIJK
The Netherlands
Reply With Quote