Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls

Wholesale userid queries

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #1  
Old 12-22-2004, 12:10 AM
 
clubsrefinished clubsrefinished is offline
 

Member
  
Join Date: Dec 2004
Location: West Midlands, UK
Posts: 15
 

Default Wholesale userid queries

Merry Christmas guys.

On our site we deal with both the general public and more increasingly trade customers.

What I am looking to do is to give the appearance that the site has a trade only section with a trade login page for trade customers to login to.

Is it possible to have a login page which will only allow wholesale userids to login and restrict the login of other memberships? I am assuming that an 'if' statement would be required but does anyone know the 'if' statement that would work for this situation

Also is it possible to have certain sections visable only when a wholesale userid logs in i.e. within the head.tpl I want to display the default top_menu.tpl at all times except when a wholesale user logs in where I would want to to replace the default top_menu.tpl with an amended .tpl called top_menu_trade.tpl. I have attempted the following logic

{if $usertype eq "C"}
{include file="customer/top_menu.tpl"}
{/if}

{if $usertype eq "B"}
{include file="customer/top_menu_trade.tpl"}
{/if}

Unfortunatelty this does not work as there is no change whether a regular or trade userid logs in. Can anyone advise what am I doing wrong??

Any help would be greatly appreciated.
__________________
Mike
--------------
Version: 4.0.11 Live, RMA, AOM & X-Affiliate
PHP 4.3.4
MySQL server 3.23.58
MySQL client 3.23.58
Web server Apache/1.3.29 (Unix)

Site: http://www.clubsrefinished.co.uk
Reply With Quote
  #2  
Old 12-22-2004, 06:37 AM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

heres a starter

http://forum.x-cart.com/viewtopic.php?p=69941#69941

user type B is for partners

you would need to check something like

Code:
{if $user_membership eq "membership_type"} {include file="customer/top_menu_trade.tpl"} {else} {include file="customer/top_menu.tpl"} {/if}
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 05:08 AM.

   

 
X-Cart forums © 2001-2020