Instructional Design Resources

Librarians sharing cool stuff

css hacks September 24, 2007

Filed under: css — kimv @ 7:06 pm
Tags: ,

I had become pretty good at making browsers behave, but IE 7 had thrown me for a loop until, I discovered this little hack. If you’re having problems getting a style to render the same way in each browser try this:

height: 500px (recognized by firefox, IE 6, IE 7, etc)
#height:450px (recognized by both IE6 and 7, but will be ignored in firefox)
_height:400px (only recognized by IE 6, and will be ignored by other browsers)

This allows you to set a different style attributes for each browser so the page will render correctly no matter which browser the you are using.

See: for more details regarding IE6


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s