HTML Samples

Fairlight fairlite at fairlite.com
Wed Jun 28 15:39:07 PDT 2006


In the relative spacial/temporal region of
Wed, Jun 28, 2006 at 11:33:34AM -0500, Lerebours, Jose achieved the spontaneous
generation of the following:
> 
> In the event that one of these macros is not parsed and replaced,
> the browser will strip the page and show NULL or BLANK cells.  In
> worse case scenario, you will see the macros as TEXT.  
> 
> I do not know HTML to emit erros, XML and/or JavaScripts do, but HTML
> itself is very forgiven.

That's a complete misnomer that needs dispelling.  HTML is neither
forgiving nor unforgiving; it is the software which interprets the HTML
for rendering (or parsing in B2B applications) that is often (too)
forgiving.

XML has a standard that was set down way after HTML.  It has a definite set
of rules, and most things are coded to observe them--or end up not working.

Browsers in particular have been fast and loose about what they do with
HTML that is incorrect.  -Technically- speaking, you should never have
attribute=value instead of attribute="value", you should actually always
wrap it in <html></html> tags, and you -should- do any number of things.
There are an apalling amount of things that most browsers have let you
get away with since ye olden days that are actually not technically up to
spec.  The mix of standard revisions is also problematic; technically you
should -not- be able to mix CSS and HTML 3.2 style formatting, yet I saw
someone doing just that about two weeks ago.  That kind of behaviour
-should- throw up huge exceptions, not make assumptions about what to do.
I an ideal world, it would.

There was also the joy of AOL's custom browser back in the day, which would
fail to display -any- of the page if you used a <center>anything</center>
anywhere inside a table's cells, despite the fact it's technically legal
(or was when I used it, many years ago).

To be clear:  The error handling and "stretchiness" of HTML is actually
implemented at the browser level, not at the language specification level.
People simply abuse some of the most common things browsers will handle a
particular way out of poor design, and get away with no errors.  Since
we're no longer in a 2-browser war here, but have many different browsers
available, it behooves one -not- to do anything non-standard or make any
assumptions that something will be interpreted a particular way if its
behaviour is not clearly defined by the actual specs.

If you rely on broken "features", be aware that they may one day be fixed,
and your code will no longer function as intended.

mark->


More information about the Filepro-list mailing list