Page 1 of 2 12 LastLast
Results 1 to 10 of 19
  1. #1
    Join Date
    Mar 2009
    Posts
    9
    Plugin Contributions
    0

    Default Changing Category font size

    Alot of people keep asking this, and alot of people keep giving out complex answers to a simple fix. Overcoding an easy fix just provides more room for problems. Its like my programming teacher used to say Keep it simple. Simplicity is key when making changes to code and writing new code. It Allows the code to run smoothly and execute properly.

    If you are looking to change the color of your categories fonts or even the size it is simply fixed through your stylesheet.css
    found in:
    /includes/templates/your_template/css

    Your stylesheet.css is part of the major framework to your site and zencart. If you are looking to make changes on a global change to the site always refer to your stylesheet.css

    simply open up the css folder and find your stylesheet.css file and open it up with and editor such as notepad.

    scroll down the sheet towards the bottom till you come to this line

    /* categories box parent and child categories */

    under this you will also see the following code.

    <Code ----
    A.category-top, A.category-top:visited {
    color: #1217FB;
    text-decoration: none;
    }
    A.category-links, A.category-links:visited {
    color: #004080;
    text-decoration: none;
    }
    A.category-subs, A.category-products, A.category-subs:visited, A.category-products:visited {
    color: #000000;
    text-decoration: none;
    }
    ---- Code>

    Note: When you look at the code you will see their is no declarations of font size, there for a default font size is chosen.

    To fix this issue you need to add this code:

    font-size: 1.2em;

    adjust the numbers to your liking to fit your template style or look.

    Once you have added the statement to the code it should look like this.

    A.category-top, A.category-top:visited {
    color: #1217FB;
    text-decoration: none;
    font-size: 1.2em; <--------------------
    }

    Once done backup the original and put it in a safe place then save the new file with the same name stylesheet.css

    then overwrite the old file in the file server.

    once completed return to your site and press F5 to refresh the page and to see your changes.

    Unlike other peoples approaches to fix this issue this addresses it the way it should and the real right way to address the issue. Note: to everyone editing their zencart and customizing it. Always refer to your stylesheet.css when trying to make a global change to your site. Your stylesheet.css is your framework to the site and therefor will contain code that will effect your site with global changes.

    I hope this helps you out.

  2. #2
    Join Date
    Sep 2009
    Posts
    1
    Plugin Contributions
    0

    Default Re: Changing Category font size

    Thanks for the info. I'd like to know how to change the sub category font color and the sub sub category font color in the left hand box as well. My list will go down multiple tiers so this is a way to keep it organized. My site is at http://www.newwayinvest.com/catalog. So far I've kind of got it, but not really, I suck at CSS.

  3. #3
    Join Date
    Mar 2009
    Posts
    9
    Plugin Contributions
    0

    Default Re: Changing Category font size

    i just takes time and practice. Once you mess with it for a while it becomes sencond nature. And easier as you go on to make changes quickly to your site.

  4. #4
    Join Date
    Oct 2009
    Location
    Dutch,
    Posts
    25
    Plugin Contributions
    0

    Default Re: Changing Category font size

    Cheers,!

    It's nice that people take the time to explain such things,
    Makes it easier for me to understand the css !
    Suddenly I saw it,

    I zenned.

  5. #5
    Join Date
    Dec 2009
    Location
    Canada
    Posts
    160
    Plugin Contributions
    0

    Default Re: Changing Category font size

    Hello,

    I followed your tips and got it to partially work... The colour reflects however the font size doesn't... could you shed some light?

    Code:
    A.category-top {color: #1217FB;text-decoration: none;font-size: 3em;}
    thelittlestgiftboutique.com/teststore/


    Thanks =]

  6. #6
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Changing Category font size

    Your stylesheet_betterCategoriesEZInfo.css is loaded after stylesheet.css (so takes precedence where there is a conflict), and has rules that affect the same elements by different names.

  7. #7
    Join Date
    Jan 2007
    Posts
    59
    Plugin Contributions
    0

    Default Re: Changing Category font size

    Thanks for the easy explanation of the font size but how about the actual font itself? What if I want to use something else? Is that in the stylesheet? Also what if I want to bold the font?

    Thanks!

  8. #8
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Changing Category font size

    Same basic answer... add a declaration to the appropriate rule for the property you want to change.

    A.category-top, A.category-top:visited {
    color: #1217FB;
    font-family: verdana, arial, sans-serif; /* font1st_choice, font2nd_choice, fallback; */
    font-weight: bold;

    text-decoration: none;
    font-size: 1.2em;
    }

  9. #9
    Join Date
    Dec 2006
    Location
    France
    Posts
    67
    Plugin Contributions
    0

    Default Re: Changing Category font size

    "/* categories box parent and child categories */"

    I would love to try this , but it does not exist in my stylesheet. using Glacial Age Template Design by Clyde Jones

  10. #10
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Changing Category font size

    Just add rules to your stylesheet if there is not already one for the element selector you want to change.
    A link to see your site live will let us give accurate advice.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Changing font size in about us category
    By lucecita2618 in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 24 Jun 2015, 12:16 PM
  2. Changing font size
    By toodamnbroke in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 6 Oct 2011, 05:47 PM
  3. Changing Sub Category Font Size found under Category Description
    By Market with a G in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 3 May 2011, 10:44 PM
  4. Global Font Size Setting: Changing Percentage and related EM Font Sizes
    By Donn in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 16 Feb 2009, 09:20 PM
  5. Changing Sub-Category Font Size
    By dwessell in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 23 Dec 2008, 10:14 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR