Forums / Templates, Stylesheets, Page Layout / Change colour of Product Counts

Change colour of Product Counts

Locked

Started by markov on 8 Oct 2006, 3:44 AM · Views: 2,164

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
8 Oct 2006, 3:44 AM
#1
markov avatar

markov

New Zenner

Join Date:
Sep 2006
Posts:
32
Plugin Contributions:
0

Change colour of Product Counts

Hi there,
Can anyone point me in the right direction. I want to change the colour of the Products Counter in the Categories sidebox (nb. it lists the number of products).

I want to keep the main text black but change the colour of the number value and remove the brackets. I know I can probably achieve this with CSS but I need to know which and where in a PHP file that I need to place my class and to remove the brackets.

thanks

8 Oct 2006, 4:00 AM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Change colour of Product Counts

The brackets can be removed via the Admin:
Admin->Configuration->Layout Settings->Categories Count Prefix
and Categories Count Suffix

To change the text color, you can likely do it safely by setting a color in CSS for

#categoriesContent.sideBoxContent

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

8 Oct 2006, 4:39 AM
#3
markov avatar

markov

New Zenner

Join Date:
Sep 2006
Posts:
32
Plugin Contributions:
0

Re: Change colour of Product Counts

Perfect - Thanks very much for the quick response

8 Oct 2006, 4:45 AM
#4
markov avatar

markov

New Zenner

Join Date:
Sep 2006
Posts:
32
Plugin Contributions:
0

Re: Change colour of Product Counts

Sorry DrByte - I was a bit too quick on my reply. I can understand that DIV call no probs - actually I am using the BetterCategories mod - so I can change the text colour in the stylesheet_betterCategoriesEzInfo.css.

However - I want to split the colours - hence the product name colour remains the original colour and ONLY the product counter number colour is changed.

Any clues?

8 Oct 2006, 4:53 AM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Change colour of Product Counts

If you were using the standard Zen Cart categories sidebox, then the non-link text would show in the color you specified via the selector I mentioned earlier.

As for the so-named BetterCategories mod, you'll have to dig into the code to find out how to add an appropriate span around the numbers and then add a class to the stylesheet to style it.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

8 Oct 2006, 5:10 AM
#6
markov avatar

markov

New Zenner

Join Date:
Sep 2006
Posts:
32
Plugin Contributions:
0

Re: Change colour of Product Counts

Thanks DrByte - that's the bit I am having trouble with. I am PHP deficient and I don't know where the code is to put the span on. Anyone want to jump in here?

8 Oct 2006, 5:48 AM
#7
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,511
Plugin Contributions:
176

Re: Change colour of Product Counts

try changing the '(' and ')' that were set for prefix/suffix in the admin to be '<span class="myCatCount">' and '</span>', respectively

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

8 Oct 2006, 11:03 PM
#8
markov avatar

markov

New Zenner

Join Date:
Sep 2006
Posts:
32
Plugin Contributions:
0

Re: Change colour of Product Counts

Thanks very much - that worked a treat - excellent - you have opened my eyes up to how I can add CSS through the form field inputs.