HTML 4.01 Transitional DTD is the answer?

There is no best practice with the DTD. As Yoda was wont to say, “There is no try, only do or not do.” Likewise with the grammar; your markup either is either valid or not valid according to the DTD.

you seem a bit rigid with the way i have to do things, with no real reason. last that i recall, all this things are part of a bigger interconected [sic] scheme and separating them creates the confusion you acuse [sic] me off [sic]
The user agent, usually a browser, creates a document object model (DOM), which the CSS and client side scripting language apply against. Again, the DTD is the grammar the UA uses to build the DOM. Invalid markup causes the UA to apply error handling routines as best they can. Valid markup means the UA doesn’t have to guess, and there is less chance of a total ****-up. Again, you’re either writing valid markup or not. There is no best practice or even leeway.

[…] (which i appreciate it as a way to discredit a person rather than an idea, a technique i would appreciate if you would not further use it on me in the future).
Let’s take a look at what I actually said, since you so completely misinterpreted it.

As I read through this thread, I could only think that noonnope has a complete misunderstanding of what a DTD is, […]

Where noonnope got off track is in confusing the DTD and best practice.
That looks nothing like what you’re whining about. First, I said you had a misunderstanding where the DTD was concerned, and went on to describe where you were wrong in your assessment. Then I said you confused two different things with one another. Again, that’s not a personal attack on your person.

Had I said you were a confused individual, incapable of understanding such a simple concept, that might be considered an ad hominem argument. I said no such thing, though I am coming to suspect it may be true.

gary

this is where we seem to have a disagreement. at the time, presentational HTML 3.2 tags were the targets, being the main exponents for one of the concepts html 4 was laying down: separation of content from presentation. those specs did not limit that rule to only these cases, but it means to target all of the markup used only for presentation. they were targeted mainly as being the big culprits at that moment. this doesn’t stop us to extrapolate the concept to all of the markup that will be impossible to be forseen the moment specs got out, markup that breaks the rule of separating content from presentation. let’s not pretend rounded corner techniques means divs used as presentational hooks for content, that’s my point.

this is one thing i would love to discuss more. i think it will bring light to that one:

is it worse than the use of xhtml only to say that is helping you with writing down a correct code? and then go ahead and serve it as html? which is a pretty common way of doing things in web programming. not that i endorse this practice at this moment. i embraced html 4.01 strict.

i seem to be forced to remind you again: it’s what i don’t want strict to be used for. i never intended to imply new uses for strict. on the contrary, it’s the limit in it’s use, given certain cases, in favor of transitional.

divs and spans are used when semantic neutral elements are needed, that’s my understanding, as presentational hooks for content. but these techniques employ empty divs and spans, with no semantic meaning whatsoever. and there is no content in them.

which is about to change, will be no longer needed. so i think i need to adjust in advance.

leaving aside technical talk, describing only a half truth, you just confirmed what i was whining about. thank you.

@deathshadow60

you’re a strong opinionated person. i respect that. i’m a more tone down person. if you can respect that it’s ok. if not, it’s also ok. just don’t expect me to engage you in another back and forth, tabloid style.

if you think an idea is stupid, say that. no need to resort to personal attacks and intimidating violent tone. i could also assume and divagate about you as a person, but that’s not civil in any way. if you’re that curious about my nationality i can always extend an touristic invitation for you to see the country i live in.

if you refer to rounded corner techniques or some image replacement techniques, those specific divs and spans are not used as hooks. it’s a hook when it involves actual content. otherwise they are just empty meaningless shells that don’t belong there.

and probably having a lack in success either. switching sides probably took place the moment i commented on your example, maybe?

I’ll repeat what I said before:

You might just have to accept that what you want the Strict doctype to be used for is never going to happen.

The standards are the standards, and HTML 4.01 has been a standard for over 10 years. You can’t retrospectively change the rules. As DeathShadow has made absolutely crystal clear, what you are calling “abuse” of elements is the exact purpose for which we have those elements.

Now please, let’s have an end to it.

which i think is … not good. that’s all. i’m not trying to pass a law.

it does, with the exception of HTML 3.2. like this:

The transitional doctype is specifically there to indicate that the page contains elements (or constructs) that have yet to be replaces.

mere use of commenting is not the best way to force techniques like rounded corners or image replacement, out of the markup some day. i think using transitional DTD as a more radical solution would prove more effective (and more dramatic, some may say).

i’ll take the rest under advisement, as a very good piece of knowledge you always provide.

you are keen on using an violent language, and spin the things i’ve said. i would appreciate if you would stop that.

if your only point is that i don’t like div and span, you are wrong. i love them. and support their use. i’m saying this again: i love div and span. can we please get over this? need i say it again? look below, it’s too many times said already.

the moment we start adding elements only as presentational hooks, like div, span, or any other element for that matter, but solely for the sake of presentation, just to be targeted later on with css (rounded corners techniques and others alike)

using divs or spans to give structure to the document, that i believe it’s ok. using divs and spans as hooks for simple presentational feats i believe it’s ok still. things are changing the moment you begin adding divs and spans for rounded corners or image replacement techniques. it’s too much, and your pretending to separate the content and presentation is already gone out the window.

basically, what i’m saying is this:
-if one uses semantically neutral elements like div and span for the use of the actual content, that still qualifies as strict.

  • if one is going to abuse a strict only to achieve some presentational feats like rounded corners with images or others like that, feats that are making a heavy use of unnecessary (when it comes to actual content) elements, one should be honest about his intentions and change the DTD to transitional.

so if you are using elements for presentational feats only, that have nothing whatsoever to do with the structure or the presentation of the actual content (no matter what elements are those), your document may validate as strict (and that can happen also with a lot of openly declared transitional documents), but it really means transitional. it’s (hopefully) still looking for a way to ditch those elements used only for presentation outside the content point of view.

i’m ok to using outerWrapper, header, footer divs. these are not the divs or spans that bother me when used as presentational hooks. these are normal uses for them. going overboard with that: empty, nested empty, empty neighboring divs and spans (or any other elements for that matter), just for the sake of a presentational feat that doesn’t relate to the actual content not even a bit, those are my focus.

because i love them so much, as presentational hooks or as pure elements, it hurts me to see them abused and being said it’s legal (strict). it’s not (it’s transitional). a better time will come for them, when they will not be slaves for techniques of pure useless presentation that have nothing to do with content. i fight for their rights.

do you love your div and span? or are you just abusing them? then legalize it, put a transitional on it. you’re about to set them free in the near future.

probably you misunderstand. when i say change strict to transitional, i only refer to those specific documents that are truly strict, but use those specific content indiferent techniques, like rounded corners or image replacement, we still need to use. i don’t advocate in any way going back to using transitional along with all the deprecated elements.

putting this exclamation mark on them, you’ll have (or the person after you) a clear inventory of things to work on in near future, as well as a method to remind you (or the person after you) just that. you’ll see a transitional DTD and wonder, and then remember (or the person after you): oh, i have in this document a deprecated presentational technique that it’s not targeting any actual content at all. i remember now. ok, let’s go to work. clean up the markup from this technique, use new ways to achieve the same result, change DTD to strict. job done.

well, what if i try and discuss a best practice involving the use of DTD? am i alowed to do that? you seem a bit rigid with the way i have to do things, with no real reason. last that i recall, all this things are part of a bigger interconected scheme and separating them creates the confusion you acuse me off (which i appreciate it as a way to discredit a person rather than an idea, a technique i would appreciate if you would not further use it on me in the future).

what maintenance nightmare? when you’re gonna clean up your code, and if you take your self seriously you will eventually, that means also changing transitional to strict in your DTD, and only for those documents that employ techniques like those specified already. and this time you’ll probably end up with a strict, no matter how you look at it.

i don’t like the idea of hidding behind a century old spec to justify the use in strict of some old techniques wearing emperor’s new clothes. i have to decide in the present and for the future. <font> and divs or spans used for rounded corners or image replacement fall in the same category. elements that mix with the content to create useless presentation (as far as the content is concerned). that belongs to transitional. then and now. one circumvents the content free of presentation concept by pretending that the use of valid strict elements for presentational only purpose it’s ok. it is, it’s just not strict.

div and span have a role to play in strict along with content. outside content concerns, these are equal to deprecated elements. it’s a repetead mistake this use, and i believe it should be amended. by labeling it as a transitional way of doing things, until the moment a better way comes your path. maybe you’re not able to switch to this other path yet, so, until that updating time comes, put some mark on those that need to be changed: transitional DTD. it’s unorthodox? maybe, but it’s less unorthodox then those convoluted contraptions named rounded corners techniques or image replacement techniques.

to formulate in another way:

html 4.01 strict( css 2.1)(w/ presentation techniques outside content point of view) doesn’t equals
html 4.01 strict(css 2.1)(w/o presentation techniques outside content point of view).

and even more so

html 4.01 strict( css 2.1)(w/ presentation techniques outside content point of view) doesn’t equals
html 4.01 strict(css 3)(w/o presentation techniques outside content point of view).

the simple fact of css 3 draft appearing and making possible to do some things differently in html 4.01 strict, is changing the way we judge these otherwise semantically correct, but presentational oriented only, outside content point of view techniques, and the documents comprising them, and alters the meaning of strict. as it should. when css 3 becomes standard, i don’t think html 4.01 will become deprecated. adjustments are in place for older standards. that’s what i believe.

i can see that there are drawbacks in that and possibly divergence, but these still exist today with the current way of judging and misuse of transitional and strict.

Let me put it another way:

HTML 4.01 Strict does not equals best practice.

Yes, a page that employs best practice will validate against a Strict doctype, but that doesn’t mean that a page that validates against a Strict doctype uses best practice, and that was never the intention.

Validation against a doctype simply means that a site conforms to a particular structure and standards, as can be verified by an automatic checking procedure. Transitional simply means that it uses elements that have been deprecated. You might disagree with whether that is the way it should be, but it is the way it is.

See http://validator.w3.org/docs/help.html#validandquality

i can see that there are drawbacks in that and possibly divergence, but these still exist today with the current way of judging and misuse of transitional and strict.

You might just have to accept that what you want the Strict doctype to be used for is never going to happen.

i agree then :slight_smile: i miss the point of strict looking at it one way, and you miss the point of strict looking at it another way. i believe strict also speaks about the actual architecture of the markup you use, not semantics alone. you say that if semantics doesn’t get hurt, markup can be a little bit more convoluted. ok. :cool:

and i also believe that things in the browser war will expedite at one moment the updating and the disappearing act issues. that’s why i don’t believe it will take that much. and even so, years pass by with the speed of light. if it wasn’t tied up that much with html5, css3 would’ve become useful to us much sooner.

i don’t support the stoppage in the use of rounded corner technique or some other techniques, if that’s what you think. i just see fit a more proper underlining of the web pages using them, for a better distinction among true strict web pages and make believe strict web pages, using other judging factors aside validation as well. there are many web pages out there that take advantage of that validation icon. it only fair to find a way to amend them, taking account of the future of the web programming also.

Which is what I mean by missing the point of strict, which is not to say “don’t use empty meaningless containers as hooks” – because that’s not what STRICT means.

You’re reading WAY too much into it. Though I agree it will be nice to be able to stop doing it in the six years to decade or so from now when CSS3 is real world deployable. (since to do so IMHO we need not only for it to reach recommendation, we should wait until IE8 is a long-gone memory)

Stevie D and gary.turner are right. just not about my supposedly confusion :slight_smile: looking at how oversimplified they describe things, it will be almost impossible to do that.

they forget one thing: different DTDs means different best practices for each. where is that leaving us? DTD’s also have attached to them some meaning, their validating rules have a meaning. otherwise they’ll be just meaningless rules.

i don’t know where did the two of you get offtrack and say that i want to use strict for something. or change anything in any of them. i just want an adjustment in thinking. don’t say strict and mean transitional. say transitional with hopes of getting better. in fact, i don’t want to use strict DTD when i use deprecated (or soon to be deprecated) techniques. that’s what transitional DTD is for. and we should adjust accordingly. at the time of their creation, nobody knew that techniques like rounded corners would appear and abuse the markup strict tried to clean up. if they known it i’m sure a recommandation against these techniques would have appeared written in those specs. just because a recommandation regarding a technique it’s not there at the time of the writing, doesn’t validates it’s use along with a DTD or another.

you are stripping the meaning out of DTDs and make out of them mindless validation rools. it’s ok, if you don’t care to think too much about what it means adopting one and you just need something to show off for: look, it’s strict, i have the icon.

choosing a DTD or another also fals into this category of best practice. unless you are shakespeare, than you can’t use a grammar only for syntax purposes, leaving semantics behind. i’m sure you can’t produce great work that will justify that.

i’m not trying a spin. i made it very clear: the use of valid strict elements to achieve transitional techniques are turning an otherwise strict validated document in a wolf in sheeps clothes. and this wolf should be exposed as a “modern” transitional.

a very good point. still, i would like to add one scenario to that. suppose we get css3 as a widely supported cross browser standard. for the rounded corners technique we’ll then have two ways of doing things:
-the old way

  • and the new way

we’ll have then two types of (html 4.01, i’m not talking about other possibilities) web pages, that have equal sign between them (they are both strict), but one of them is an example of bad practice. how will a wanting web programmer know to follow the good one (other that browsing sitepoint’s forum :wink: ) ? why will the creators of the web pages employing the old way would even bother to embrace the new way (other than the fact that it will clear up their web page markup, but that means more work) ? because now, if he employs a similar bad habit, like using <font> instead of css style, he will not have it’s code validated as strict.

whereas, their page being marked as transitional would be a good reason to go ahead and ditch that old way when the time comes. maybe it’s going to the extreme.

yes, but when you do that you should also plant an exclamation mark. let DTD transitional be the one, that’s all i’am saying.

i’m nothing but a zen person. i see i have to repeat my self:

i’m ok to using outerWrapper, header, footer divs. these are not the divs or spans that bother me when used as presentational hooks. these are normal uses for them. going overboard with that: empty, nested empty, empty neighboring divs and spans (or any other elements for that matter), just for the sake of a presentational feat that doesn’t relate to the actual content not even a bit, those are my focus.

As Gary says above, merely making sure your page validates to a strict doctype does not, by itself, mean you have a well designed page. It is merely one step along the way to that goal.

You can have a page that uses a strict doctype and validates 100%, but is still utter crap. Well, you can build a lousy house on top of a good foundation too. That doesn’t mean the good foundation is a bad idea, does it?

it’s past edit time, so an addendum is in place. sorry for that.

i think we didn’t really needed html5 new feats that much. we needed css3 helping html 4.01 strict be a real strict.

and at least as a sign of honesty to my self, as a web programmer, when bloating the markup (even if not affecting the semantics) for the sake of certain presentational feats, i should be honest and put a transitional until i find a better way. this will keep me going in the right direction and if used as a more general rule will help make a pretty clear distinction between a table layout that some will now mark as a strict DTD and a real strict one. validation alone using a validator will not necessarily and absolutely describe a strict.

I understand what you’re saying (I think), but I’ll say that the answer – in the general case – is no.

Firstly, from a stricly technical point of view, we’re not straying from the Strict DTD to the Presentational DTD unless we use any of the element types or attributes that are included in the latter but deprecated in the former.

But are we using presentational markup in a way that is counter to the original ideals for HTML? Yes, we are. It’s currently unavoidable due to the limited means that CSS2.1 provides for controlling layout and for adding decorational flourishes. (Well, to be honest, the lack of browser support for the features that do exist is even more limiting.)

Adding one or two wrapping divs around blocks of content is nothing that should make the Semantics S.W.A.T. Team come crashing through our windows at night. That’s just content grouping, which is one of the purposes of the div element type. As long as we don’t go overboard and create the deeply nested horrors that gives deathshadow60 an apoplectic fit, we’re fine.

Using empty elements to create ‘hooks’ for styling is less acceptable, but unfortunately necessary for some types of design. This should peter out by itself eventually, with the arrival of CSS3’s border-radius, multiple background images, etc. And, of course, the gradual disappearance of non-CSS2 browsers like IE7 that don’t support the ::before and ::after pseudo-elements.

Then there is another practice that I don’t hesitate to call despicable: abusing element types with specified semantics for ulterior purposes. The classic example of this, of course, is abusing tables for layout purposes of non-tabular information. Using blockquote to indent text is another. These practices are becoming increasingly rare among (true) professionals, though.

But – and here is probably where a larger group of people will begin to disagree with me in earnest – there are more subtle practices that are getting more and more common, even among those who really should know better. I’m talking about wrapping pairs of labels and input fields in paragraph tags to ‘avoid divitis’. I’m talking about marking up forms (in general) using ordered or unordered lists, or even definition lists. I’m calling this hypersemantics, analogous with hypercorrection.