[TYPO3] HTML 4.01 Strict?

Christopher bedlamhotel at gmail.com
Tue Sep 26 17:04:46 CEST 2006


Hi,

On 9/26/06, ben van 't ende [netcreators] <ben at netcreators.com> wrote:
> Matthew Manderson wrote:
> > Hi
> >
> > Anybody running TYPO3 in HTML 4.01 STRICT doctype?
> >
> > It seems not as easy as it looks. Any advice welcome.
>
> Hi Matthew,
>
> Why on earth would you want to run it on HTML 4.0.1? If you want that
> then use an older version. Can't think of any good reason though.

Why? Because if you are not serving your xhtml as
application/xhtml+xml, you *are using html anyway*. There are NO real
advantages to xhtml over html as long as it is served as text/html
[1].

>From my perspective, it's a serious deficiency in TYPO3 that *any*
x/html is hardcoded in the core and that TYPO3 explicitly chooses NOT
to support ANY current standard markup schemes--especially since most
of the problem could be solved by adding a doctype check to the page
rendering routine (simplified to make the principle clear):

if ($doctype == 'html') { $tagClose = ''; } else { $tagClose =  ' /';}

Then hardcoded 'self-closing' tags could be coded this way: echo
"<br$tagClose>", and a similar treatment could be applied to the html
tag.

However, I've been soundly trounced on the dev list for advocating
that TYPO3 support both xhtml and html. I don't really understand it
because ALL further xhtml specs are likely to be xml based so a
properly implemented check for a non-xml based doctype could not only
solve the problem now, but also be future-proof. I don't even try to
suggest that e.g. CSS-styled content should also be html 4 compliant,
just that the *core* should be so that it is *possible* to develop
other content rendering schemes.

@erik:

Purists? HTML 4.01 is a *current* standard, and is not likely to be
superseded--and cannot be said to have been improved on--until
sometime after IE7 when the majority of browsers can cope with xml.
TYPO3 is fantastically flexible in almost every other way. Why should
it be inflexible when it comes to one of its *core
competencies*--outputting markup?

-Christopher

[1] http://www.hixie.ch/advocacy/xhtml



More information about the TYPO3-english mailing list