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

Different Stylesheet for Each Manufacturer

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 10-25-2008, 01:37 PM
 
joannet joannet is offline
 

Senior Member
  
Join Date: Mar 2006
Posts: 105
 

Default Different Stylesheet for Each Manufacturer

Hi,

I was wanting to have different stylesheets for each Manufacturer.

Basically when each Manufacturer is viewed, the text, links, box headers, etc need to be unique to that particular Manufacturer.

Could you anybody advise how to achieve this?

Thanks.
__________________
/joannet/
X-Cart version 4.1.9 and above
Reply With Quote
  #2  
Old 10-25-2008, 02:12 PM
  JWait's Avatar 
JWait JWait is offline
 

X-Man
  
Join Date: Nov 2005
Location: California
Posts: 2,440
 

Default Re: Different Stylesheet for Each Manufacturer

I suppose you could base it off of the manufacturer id and have a stylesheet for each one.
__________________
Two Separate X-Cart Stores
Version 4.4.4 Gold - X-AOM - Vivid Dreams Aquamarine (modified) - Linux
Mods - Newest Products - View All -, and a few others. Numerous upgrades from 4.0.x series.
Integrated with Stone Edge Order Manager + POS

Version 4.1.12 Gold (fresh install) - X-AOM - Linux
Mods - XCSEO free
Reply With Quote
  #3  
Old 10-25-2008, 02:27 PM
 
joannet joannet is offline
 

Senior Member
  
Join Date: Mar 2006
Posts: 105
 

Default Re: Different Stylesheet for Each Manufacturer

Yes, exactly as I thought.

Would you happen to know the code to use and where to place it on customer/home.tpl or other?

Thanks
__________________
/joannet/
X-Cart version 4.1.9 and above
Reply With Quote
  #4  
Old 10-26-2008, 06:58 AM
  JWait's Avatar 
JWait JWait is offline
 

X-Man
  
Join Date: Nov 2005
Location: California
Posts: 2,440
 

Default Re: Different Stylesheet for Each Manufacturer

Well, I think a lot would depend on if you want to retain the classes from skin1.css or change them all. If you redefine a class with a new stylesheet it will be the "default" unless it is again redefined by another stylesheet. It would be the same as defining a class "last" in skin1.css, the original class would be "forgotten" with the new one. It can get very complicated very quickly.

I'm not sure of the actual syntax or variables to use, but it could be something like...

{if $manufacturerid ne ''}
<link rel="stylesheet" href="{$SkinDir}/{$manufacturerid}.css" />
{else}
<link rel="stylesheet" href="{$SkinDir}/{#CSSFile#}" />
{/if}

and put in skin1/customer/home.tpl where "<link rel="stylesheet" href={$SkinDir}/{#CSSFile#}" />" is presently.
__________________
Two Separate X-Cart Stores
Version 4.4.4 Gold - X-AOM - Vivid Dreams Aquamarine (modified) - Linux
Mods - Newest Products - View All -, and a few others. Numerous upgrades from 4.0.x series.
Integrated with Stone Edge Order Manager + POS

Version 4.1.12 Gold (fresh install) - X-AOM - Linux
Mods - XCSEO free
Reply With Quote
  #5  
Old 10-28-2008, 08:57 PM
 
joannet joannet is offline
 

Senior Member
  
Join Date: Mar 2006
Posts: 105
 

Default Re: Different Stylesheet for Each Manufacturer

Hi,

Thanks very much for your suggestions.

Most appreciated
__________________
/joannet/
X-Cart version 4.1.9 and above
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



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 02:38 PM.

   

 
X-Cart forums © 2001-2020