IE ignoring custom css selectors?
IE relieves me.
my css code looks like this:
kl {
font-size:10pt;
font-weight: bold;
color:#6e90a6;
}
and my html code looks like this:
<div id="testid"><kl>test</kl>
Why is IE ignoring my CSS?
Are you creating custom tags? IE handles custom tags differently than other browsers.
Why not use span and class, I think IE6 might be better responsive, simple.
<div id="testid"><span class="kl">test</span></div>
.kl {
font-size:10pt;
font-weight: bold;
color:#6e90a6;
}
I would use a css class or an id, but if YOU MUST have your own tag then I believe you need to define your tag in XSL and then include it in your page so IE can recognize it.
Cl? Try it...
CSS
#testid span {
font-size:10pt;
font-weight: bold;
color:#6e90a6;
}
HTML:
<div id="testid"><span>test</span></div>
In late 2008, Ajaxian published an article that looked at how to embed custom tags in IE, along with adding CSS to those tags. You can read a short text here:
Adding custom tags in Internet Explorer, the official way
Why don't you do this for your css:
#testid (
font-size:10pt;
font-weight: bold;
color:#6e90a6;
}
This should work. Though you should be aware that IE (especially <7) is less than CSS compliant.