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 2 of 2
  1. #1
    Join Date
    Feb 2004
    Member #
    I'm trying to apply 1 link stye to 2 different DIVs which kinda works, atleast for one DIV. The text in the other DIV gets bolded and underlined and the links default to the normal blue while the text & links in the other DIV has the propper styles applied to it.

    you can see what i mean here

    Now depending on which DIV I put first changes which DIV gets the propper style. I am using this code in the style sheet:

    #mainmen,news a:link {

    #mainmen,news a:hover {

    #mainmen,#news a:visited {

    So for example if I put #mainmen first then all the text in this DIV gets bolded and underlined while the links default to the default colours, while the texts and links in the #news DIV gets the propper style. If i put #news DIV first then the #mainmen DIV gets the propper styles and the #news div gets messed up.

    I have racked my brains, Googled but to no avail I couldn't find a solution or come up with one short of writing the same styles for each DIV and applying them sepratly.

    Does anyone have any ideas as to what is causing the problem or a solution?



  3. #2
    Senior Member Fallout's Avatar
    Join Date
    Aug 2003
    Richmond, Virginia
    Member #
    The # before a class name means it is an id and therefore unique in the document. If you try to apply this to multiple elements, only the first will take the style. Try using ".mainmen" instead, and then you can apply it as many times as you would like.

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:46 AM.
Powered by vBulletin® Version 4.2.3
Copyright © 2020 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: