Reply to Re: closing the link tag in HTML strict

Your name:

Reply:


Posted by petermichaux on 10/02/06 17:10

Benjamin Niemann wrote:
> Hello,
>
> petermichaux@gmail.com wrote:
>
> > When I validate a HTML 4.01 STRICT document it doesn't like to see a
> > closed tag like this
> >
> > <link rel="stylesheet" href="base.css" type="text/css"/>
> >
> > but it is happy with
> >
> > <link rel="stylesheet" href="base.css" type="text/css">
> >
> > Does anyone know why the link cannot be closed in HTML?
>
> LINK has the content model EMPTY - this means that it cannot have any
> content and must not have an end-tag.
>
> <ELEM .. /> is a short-hand for <ELEM ..> .. </ELEM> *in XML*, but HTML is
> based on SGML, which does not have such a syntax (it does have a similar
> looking syntax with a complete different meaning).
> XML introduced this short-hand syntax, because it does not know the content
> model EMPTY, but elements without content are pretty often used.
>
> > It seems
> > strange if HTML 4.01 is supposed to be closely parallel with XHTML.
>
> HTML 4.01 is older than XHTML and it was never supposed to have anything in
> common with XHTML. XHTML 1.0 on the other hand was supposed to be a
> semantically equal reformulation of HTML 4.01 with the slightly different
> XML syntax rules.
>
> HTH

Hi Benjamin,

Thank you for the informative response. My misunderstanding was that
the XHTML reformulation was supposed to be a little closer to HTML than
it actually is.

Thanks again,
Peter

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация