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

Change colour of Product Counts

Locked

Views: 2,160

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,513
Plugin Contributions:
177

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
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,513
Plugin Contributions:
177

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.

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,513
Plugin Contributions:
177

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

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.