Sent by Alan Gresley on 18 July 2009 17:05
david wrote:
> Alan Gresley wrote:
[...]
>> Hello Erik,
>>
>> This is still hacking HTML for IE7 or lower due to lack of support for
>> CSS2.1. My CSS and hacks are *centralized* as oppose to being
>> *decentralized* in the HTML. They can be removed in a flash.
>
> All your conditional comment (in the HTML) needs to contain is a style
> link pulling in whatever stylesheet you want to feed IE. Then your CSS
> is not in the HTML, just the stylesheet an IE browser pulls in when it
> processes your conditional comment.
This is what I do anyway by this.
@import test-ie; /* For IE/Win */
All other browsers (non IE7 or lower) will skip that import since it is
invalid.
All comments <!-- --> are downloaded by every browser. Even if the code
is a server side template, each and every page visited by a browser has
to download such possible code.
<!--[if lt IE 7]>
<link rel="stylesheet" type="text/css" ref="site.css" />
<script type="text/javascript" src="sfhover.js"></script>
<![endif]-->
Though with my CSS file with IE @import, all browser have the CSS
already cached so is only downloaded once. If I wrong in this, please
point out my error.
--
Alan http://css-class.com/
Armies Cannot Stop An Idea Whose Time Has Come. - Victor Hugo
______________________________________________________________________
css-discuss [EMAIL-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/