WordPress.org

Ready to get started?Download WordPress

Forums

Help a newbie change link color (5 posts)

  1. jlennon931
    Member
    Posted 7 years ago #

    I need to change the link color throughout the page. Sidebar, footer, and page content.
    My web site is http://www.shiitakefarm.com
    CSS is over my head right now. Maybe I'm in over my head.
    Please help

  2. ryanarrowsmith
    Member
    Posted 7 years ago #

    Well, there's no way to do it without altering the CSS. In short, your link properties will have an "a" involved. Example:

    a {
    color: #06c;
    text-decoration: none;
    }

    a:hover {
    color: #147;
    text-decoration: underline;
    }

    A stand-alone a is the base link color. It's your default style that will effect all of your links. a:hover is how your links will appear when hovered over.

    You're going to see lots of link styles in your stylesheet" h2 a, h3 a, etc. All of those are saying, if the element h3, which is a heading element, is a link, display it as follows. Does that make sense?

    To change the color, you need to know the hex value of the color you want. Try colorschemer.com/online/ if you don't have Photoshop.

  3. jlennon931
    Member
    Posted 7 years ago #

    Thank you so much

  4. Rekzai
    Member
    Posted 7 years ago #

    What if I wanted a different color for the sidebar links then the links in the post or the links in the comments ??

  5. webophir
    Member
    Posted 7 years ago #

    if your page structure is like this:
    <div id="main">
    ...blah blah...
    </div>
    <div id="sidebar">
    ...blah blah...
    </div>

    Your CSS will be
    #main a {color: #your_color_value1; }
    #main a:hover {color: #another_color; }
    #sidebar a {color: #your_color_value2; }
    #sidebar a:hover {color: #another_color;}

Topic Closed

This topic has been closed to new replies.

About this Topic