AHHH,
but here you see, this is the difference between this article and what I do in general. ALA is a great resource, but.
They claim to promote web standards but are almost always throwing in a "hack" to get their article nuances to work and I quote from the above article:
"One Hack for Consistency"
I don't use "hacks" to get my stuff to work, either it uses plain markup and CSS or it don't get put in. Promoting hacks is (in a way) promoting the derogation of standards.
I suppose however, the <dl> issue could be seen as a "hack" from a certain point of view, but I don't need to tweak the CSS to get it to work.
Code: Select all
#header a {
float:left;
display:block;
background:url("right.gif")
no-repeat right top;
padding:5px 15px 4px 6px;
text-decoration:none;
font-weight:bold;
color:#765;
}
/* Commented Backslash Hack
hides rule from IE5-Mac \*/
#header a {float:none;}
/* End IE5-Mac hack */
Resorting to this is common in ALA articles; and the reason I only use basic CSS rules and markup that work without resorting to this.
Granted CSS isn't perfect when it comes to browsers, but we can use rules that most browsers will agree upon. ALA does have one article I agree with, I believe its article #173 or CSS sprites; no hacks, just good clean CSS and markup.
I challenge anyne to have a <ul> based inline menu with other <ul>s in the same page and not have it totally hose up in I.E. without resorting to some "hacK' to get the job done. Or show me a page where multiple <ul>s are used with an inline menu (again, no hacks) and I will succed from this debate.
Edited. Since I tend to use xHTML 1.1, the rules for markup and CSS engagement change. In a transitional setting this may not apply, but as web standards move forward, we will see stricter compliancy be thrown at us. Its best we learn these things instead of beating our heads against the walls wondering why this or that doesn't work in this or that browser. I.E. is the new NS4 as far as I am concerned.
In xHTML 1.1 the <ul> is further restricted and I.E. simply can't handle it right now. I use xHTML 1.1 on most my sites, with very few exceptions; the phpbb forum template I'm working on being one of those exceptions - xhtml 1.0 transitional; simply because the software wasn't really designed for a strict dtd environment.