Tuesday, July 20, 2010

Fixing Compatibility problems for IE6 and IE 7

Had a client today who gave me this task to fix some issues on CSS in IE6 an IE7.

Here is how I go with the Fixing of compatibility problems for IE6 and IE 7:

1. The * HTML tag or something
- i learned from my friend google that * HTML can be used to apply fix css codes to IE 6 and 7 as it will be ignored in modern browsers.

Sample code:
#feedbacktop {
/*background:url("#") no-repeat scroll 0 0 transparent;*/
min-height:225px;
margin-top:15px;
margin-left:0px;
margin-bottom:10px;
}

/* convert min height values for IE6*/
* html #feedbacktop {
background:url(#);
height:225px;
margin-top:15px;
margin-left:25px;
margin-right:25px;
width:350px;}

2. Conditional Comments - havent tried it though..LOL...


Or for IE7:



I have tried the first one and it worked really great for me.

No comments:

Post a Comment