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

Changing color of product variant selector

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 08-04-2006, 07:20 AM
 
soyuz02 soyuz02 is offline
 

Advanced Member
  
Join Date: Jun 2006
Posts: 71
 

Default Changing color of product variant selector

Hi,

I am seeking to change the color of the product variant selector label which is displayed on the product details page. Any ideas?

Thanks a lot guys.

And Balinor, if you read this one, thank you so much for your dedication to this forum, you've helped me loads.
__________________
X-Cart Version :: 4.1.6 (Finally)
X-Cart Mods :: Kids Skin by 7dana
Running on :: SUSE Linux 9.3 with Plesk 7.5.4
Webserv :: Apache 2.0.53
mySQL :: 4.1.10
PHP :: 4.3.10
Reply With Quote
  #2  
Old 08-04-2006, 11:06 AM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

I read every one Glad I can help!

By the selector, do you mean the drop-down box itself or the label next to it?
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 08-04-2006, 01:26 PM
 
soyuz02 soyuz02 is offline
 

Advanced Member
  
Join Date: Jun 2006
Posts: 71
 

Default

I mean the text next to it, so the label of the control. Thanks
__________________
X-Cart Version :: 4.1.6 (Finally)
X-Cart Mods :: Kids Skin by 7dana
Running on :: SUSE Linux 9.3 with Plesk 7.5.4
Webserv :: Apache 2.0.53
mySQL :: 4.1.10
PHP :: 4.3.10
Reply With Quote
  #4  
Old 08-04-2006, 01:32 PM
 
carpeperdiem carpeperdiem is offline
 

X-Guru
  
Join Date: Jul 2006
Location: New York City, USA
Posts: 5,399
 

Default

Although this post is not SPECIFICALLY how to change your specific "option" tag (actually you are not changing anything in the template -- you will be editing the CSS file), it will show you how you can figure this out on your own in about 30 seconds...

For your specific case, change step #4 to:

4. click on a product detail that has a variant

then proceed...

http://forum.x-cart.com/viewtopic.php?p=148575#148575
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4
Reply With Quote
  #5  
Old 08-04-2006, 01:36 PM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

Unfortunately X-Cart didn't bother to assign a class to that piece of text, so it isn't that easy. This is the line that controls the code, it is in skin1/modules/Product_options/customer_options.tpl:

<td valign="middle" height="25">{if $usertype eq "A"}{$v.class}{else}{$v.classtext|default:$v.class }{/if}</td>

You'll need to either add a class to it, or use <span> tags to format it.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #6  
Old 08-04-2006, 01:52 PM
 
carpeperdiem carpeperdiem is offline
 

X-Guru
  
Join Date: Jul 2006
Location: New York City, USA
Posts: 5,399
 

Default

Sorry..

I was thinking you wanted

class="ProductDetailsTitle"

or

.ProductDetailsTitle in the CSS file....

In this case, change this line of code from:
Code:
<td valign="middle" height="25">{if $usertype eq "A"}{$v.class}{else}{$v.classtext|default:$v.class}{/if}</td>
to:
Code:
<td class="ProductVariantTitle" valign="middle" height="25">{if $usertype eq "A"}{$v.class}{else}{$v.classtext|default:$v.class}{/if}</td>

then in your skin1/skin1.css - add this anywhere...
Code:
.ProductVariantTitle { color: #FF00CC; text-decoration: line-through; font-weight: bold; font-size: 14px; }

Obviously, change the CSS to match what you really want it to look like. This particular code will look pretty nasty there...

if you are not proficient in CSS editing, no worries. there are countless sites on the web with everything you need to know. You only need to know how to search for the answer...

hope this helps.

Jeremy
__________________
xcart 4.5.4 gold+ w/x-payments 1.0.6; xcart gold 4.4.4
Reply With Quote
  #7  
Old 08-05-2006, 04:07 PM
 
soyuz02 soyuz02 is offline
 

Advanced Member
  
Join Date: Jun 2006
Posts: 71
 

Default

Thanks a lot guys, it worked just fine. Just one more question:

I have one selector box which lets the customer choose the product variant. Now left of it is of course the label or name of the option group whose format I have now been able to change. However I would like to inlcude another text label on the right side of it. How would I do this??

Thanks!
__________________
X-Cart Version :: 4.1.6 (Finally)
X-Cart Mods :: Kids Skin by 7dana
Running on :: SUSE Linux 9.3 with Plesk 7.5.4
Webserv :: Apache 2.0.53
mySQL :: 4.1.10
PHP :: 4.3.10
Reply With Quote
  #8  
Old 08-05-2006, 04:08 PM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

Same template, just add a new table cell at the end.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #9  
Old 08-07-2006, 01:21 PM
 
Scott DeToffol Scott DeToffol is offline
 

Senior Member
  
Join Date: Apr 2005
Location: Minneapolis, MN
Posts: 174
 

Default skin1.css cheat sheet?

balinor or anyone - is there a good guide to skin1.css that explains in detail what the selectors affect? Maybe someone has placed a bunch of comments in that would help guide us?
__________________
Scott DeToffol
Online Marketing and E-Commerce Consulting in Minneapolis

X-Cart Gold Version 4.1.9 for www.sundogtrading.com
X-Cart Pro Version 4.2.3 for www.heavyglare.com
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:15 PM.

   

 
X-Cart forums © 2001-2020