/    Sign up×
Community /Pin to ProfileBookmark

ie fix in css file

hi,

i have to deal with ie ‘s terrible float+margin handling.
so i wrapped my <div> in another div and applied the style to it, and ie treats it ok now, but ff and the rest not.
so i need this fix to be ie-only.
how do i do that?
how do i create a style that will be ignored by all-but-ie browsers?

what im trying to fix is the top menu margin on:
w w w . v i a g r a k a u f e n . a t

thanks

to post a comment
CSS

3 Comments(s)

Copy linkTweet thisAlerts:
@webdeveloper074Aug 19.2009 — 
  • * {margin:0;padding:0;}


  • This is part of the “CSS Reset” theory which helps keep your designs consistent across browsers, a very good thing. This technique works on all browsers, so I never really considered any negatives. That is, until I read this:

    "This eliminated all differences in padding and margin across browsers so I was free to go about styling my page. Unfortunately, this isn’t a good practice. It’s very heavy on the rendering agent to apply rules to every single element in the document, especially with large web pages, and this can also destroy a lot of good default styling, especially when you want to have default styled submit buttons."

    So I would suggest you to add {padding:0;} to #top_menu ul

    #top_menu ul{

    ...

    padding:0;

    }

    This will give a default behaviour to ul under id top_menu across all browsers.

    Further you apply:

    #top_menu {margin-left:50px;}
    Copy linkTweet thisAlerts:
    @gilyotinaauthorAug 30.2009 — thanks,

    the fix did the job for the top menu,

    but when i tried the same strategie with the bottom menu - i failed.

    ff shows it fine, but with ie i get the sub-list items shifted to the right.

    any idea?
    Copy linkTweet thisAlerts:
    @webdeveloper074Sep 01.2009 — I dont see a menu at bottom on w w w . v i a g r a k a u f e n . a t

    nor do i see change to top menu. guess the files are not updated on server!
    ×

    Success!

    Help @gilyotina spread the word by sharing this article on Twitter...

    Tweet This
    Sign in
    Forgot password?
    Sign in with TwitchSign in with GithubCreate Account
    about: ({
    version: 0.1.9 BETA 6.2,
    whats_new: community page,
    up_next: more Davinci•003 tasks,
    coming_soon: events calendar,
    social: @webDeveloperHQ
    });

    legal: ({
    terms: of use,
    privacy: policy
    });
    changelog: (
    version: 0.1.9,
    notes: added community page

    version: 0.1.8,
    notes: added Davinci•003

    version: 0.1.7,
    notes: upvote answers to bounties

    version: 0.1.6,
    notes: article editor refresh
    )...
    recent_tips: (
    tipper: @meenaratha,
    tipped: article
    amount: 1000 SATS,

    tipper: @meenaratha,
    tipped: article
    amount: 1000 SATS,

    tipper: @AriseFacilitySolutions09,
    tipped: article
    amount: 1000 SATS,
    )...