Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 3 of 3
  1. #1
    Senior Member I Brian's Avatar
    Join Date
    Oct 2002
    Location
    Yorkshire, UK
    Posts
    149
    Member #
    26861
    Hi there -

    I'm still new to CSS - I've got by by simply copying and modifying simple commands from webpages I've downloaded. Thing is, I'm up against something I can't find a reference for on saved websites.

    I have simply two links in the left hand navigation bar - one should be white, and one yellow, and they should maintain their color and simply have an underline during "hover". Normal links on the page should be a different colour.

    How do I go about defining their classes?

    I'm currently using:

    body
    {
    font-family: verdana, arial, helvetica, serif;
    color: #000000;
    FONT-SIZE: 10px;
    }

    P
    {
    FONT-SIZE: 10px;
    }

    a:
    {
    color: #c0c000;
    background-color: transparent;
    text-decoration: none;
    }
    a:visited
    {
    color: #c0c000;
    background-color: transparent;
    text-decoration: underline;
    }
    a:hover
    {
    color: #c0c000;
    background-color: transparent;
    text-decoration: underline;
    }

    .leftLink {

    COLOR: #ffffff; FONT-SIZE: 10px; PADDING-LEFT: 10px; TEXT-DECORATION: none;
    }

    .leftLink:hover {

    COLOR: #ffffff; FONT-SIZE: 10px; PADDING-LEFT: 10px; TEXT-DECORATION: underline;
    }
    but I think they are conflicting with one another. Any pointers much appreciated.

  2.  

  3. #2
    Senior Member
    Join Date
    Jun 2003
    Location
    Australia
    Posts
    735
    Member #
    1935
    <style type="text/css">
    .leftlink_red{
    color: #ff0000;
    size: 10px;
    text-decoration: none;
    }
    .leftlink_red:hover{
    color: #ff0000;
    size: 10px;
    text-decoration: underline;
    }
    .leftlink_yellow{
    color: #ff0000;
    size: 10px;
    text-decoration: none;
    }
    .leftlink_yellow:hover{
    color: #ffff00;
    size: 10px;
    text-decoration: underline;
    }
    </style>


    <a href="link.html" class="leftlink_red">red link</a>
    <a href="link.html" class="leftlink_yellow">yellow link</a>

    that will work

  4. #3


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 07:42 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com