1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

CSS - more than one class...

Discussion in 'CSS' started by Lpspider, Oct 8, 2005.

  1. #1
    Okay, is it possible to list a bunch of classes that will affect the same thing?

    for this code;

    
    
    a
    {
    color:696969;
    text-decoration: none;
    width:400px; 
    height:900px;
    }
    
    
    
    
     a:visited 
    { 
    text-decoration: none; 
    color:#696969;
    }
    
    a:hover 
    {
    color:#996633;
    text-decoration: none;
    }
    
    
    Code (css):

    maybe something like this (I know it's not right)

    .content, .main, a:hover
    {
    color:#996633;
    text-decoration: none;
    }
    Code (css):
    Thanks!
     
    Lpspider, Oct 8, 2005 IP
  2. LGRComp

    LGRComp Well-Known Member

    Messages:
    516
    Likes Received:
    27
    Best Answers:
    0
    Trophy Points:
    195
    #2
    Yes that is fine. Do it all the time.
     
    LGRComp, Oct 8, 2005 IP
  3. cpmx

    cpmx Peon

    Messages:
    88
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I don't see any problem either. You could also create a new class and call it from your html.

    For example:

    
    .common {
    color:#996633;
    text-decoration: none;
    }
    
    And in your html:
    <div class="content common">
    
    This div will have both styles applied to it.
    
    HTML:
     
    cpmx, Oct 8, 2005 IP