First letter pseudo class works perfect for p element but not for anchor(links). Why?
How to make the first-letter style different for <a>
element
a:first-letter
{
font-size:200%;
text-transform:uppercase;
color:#8A2BE2;
}
First letter pseudo class works perfect for p element but not for anchor(links). Why?
How to make the first-letter style different for <a>
element
a:first-letter
{
font-size:200%;
text-transform:uppercase;
color:#8A2BE2;
}
If JavaScript is an option it might be worth looking at: http://letteringjs.com (which should be fairly cross-browser compatible)
How about this http://jsfiddle.net/raynesax/8W7FF/8/
According to the W3 spec, the
:first-letter
pseudo-element only work for a block element, whicha
is not.Oddly,
*:first-letter
caused the first letter to transform, at Chrome 14 and Firefox 3.6.23. Fiddle: http://jsfiddle.net/8W7FF/3/