SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Enthusiast
    Join Date
    Mar 2002
    Location
    Italy
    Posts
    98
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    css back to normal

    hi to all,
    i have designed a webpage using this line in the css
    @import url("IE.css");
    this allows me to set some special styles for input, textarea and select when people access the site using IE.
    however i would like to use this special styles only for the top part of my page. is there a way of setting these "back to their default values" in some way?

    thanks a lot for your help
    frodo

  2. #2
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,236
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)

    Re: css back to normal

    Originally posted by frodo
    hi to all,
    i have designed a webpage using this line in the css

    this allows me to set some special styles for input, textarea and select when people access the site using IE.
    however i would like to use this special styles only for the top part of my page. is there a way of setting these "back to their default values" in some way?

    thanks a lot for your help
    frodo
    How about putting your attributes for those inputs in classes rather than the entire element?
    Code:
    select.topForm {
     background-color: black;
     color: white;
     font-family: verdana, geneva, sans-serif;
    }
    Any <select> tags that don't have a class of "topForm" will be "normal".

    --Vinnie

  3. #3
    SitePoint Enthusiast
    Join Date
    Aug 2002
    Location
    Australia
    Posts
    56
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Another option: use descendant selectors, if the top part of your page is enclosed in a DIV. Something like:

    Code:
    <div id="topDiv">
    ... here is the top part ...
    </div>
    And in the CSS:

    Code:
    #topDiv select { иии }
    #topDiv input { иии }
    #topDiv textarea { иии }

  4. #4
    SitePoint Enthusiast
    Join Date
    Mar 2002
    Location
    Italy
    Posts
    98
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    mmmh, both ideas are sound, but for reasons of simplicity and divine html motives (meaning sometimes html seems to work on a prayer) i would prefer to add a new line at the end of my section rather than modify what is already there.

    thanks
    frodo

  5. #5
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,236
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Originally posted by frodo
    mmmh, both ideas are sound, but for reasons of simplicity and divine html motives (meaning sometimes html seems to work on a prayer) i would prefer to add a new line at the end of my section rather than modify what is already there.

    thanks
    frodo
    In that case, good luck with whatever you come up with.


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
  •