yes conditional statements are possible in CSS, but they only argue browser types. You use them as "comments". However, you cannot put the statements in the CSS file itself. You have to put it in the HTML file since a CSS conditional statement is in the form of an HTML comment. See below:
Code:
<!--[if IE]>
Special instructions for Internet Explorer would go here
p{
margin:10px !important;
}
<![endif]-->
Or if you prefer you can make it more browser specific by adding EXACTLY which browser to change the settings on, like this:
Code:
<!--[if IE 5]>
This would change settings according to whether or not the user is using Internet Explorer 5
<![endif]-->
You can also use "lt", "gt", or "lte" to specify which browser, like this:
Code:
<!--[if gt IE 6]>
This would change settings if the browser was GREATER THAN (gt) Internet Explorer 6<br />
<![endif]-->
"lte" would stand for "Less Than or Equal to"
Bookmarks