Reply to Re: Paragraph and DIV usage in XHTML

Your name:

Reply:


Posted by cwdjrxyz on 10/25/06 00:09

Harlan Messinger wrote:
> tzuchia16@yahoo.com wrote:
> > Thanks guys for replying. Your comments were very helpful.
> >
> > And my question was related to a company website, and we're using
> > XHTML. I'll look into using Strict though.
>
> Note: it's not a question of using Strict *versus* XHTML. Both HTML 4.01
> and XHTML come in both Strict and Transitional versions. Andy's main
> point was that you ought to use HTML 4.01 instead of XHTML. The Strict
> part just follows the general principle that Transitional exists to
> support existing sites, and that Strict should be used for new work.

Only the old xhtml 1.0 comes in strict, transitional, and frameset
versions. The more recent xhtml 1.1 (not so new now and a higher
version is in the works) comes in only one version, which is about as
strict as a mother superior in a 1800s convent. There is no point in
writing in xhtml and then serving it as text/html as often is done. If
you serve as text/html, then html 4.01 strict is better. If you serve
any version of xhtml with the correct mime type of
application/xhtml+xml or application/xml, then it will not be viewable
on IE6, which can not display a true xhtml page served correctly. If
you can view a "xhtml" page on IE6, then you can be certain that it is
not served as true xhtml despite a correct xhtml doctype. To get around
this problem, you would need to serve an xhtml page with mime type
application/xhtml+xml associated with an extension .xhtml or mime type
application/xml associated with an extension .xml, for example. Most
servers are set to serve a page with an extension .html or .htm as
text/html. There is a good bit of info that is exchanged between the
server and browser before a page is downloaded in the header exchange.
If this information determines that the page is being served as
text/html, then that is how the page gets served, despite an xhtml
doctype. Of course one could redefine the extension .html to be
associated with one of the xhtml/xml mime types, but then you could not
serve ordinary html with the extension .html. If the correct mime types
for the extensions .xhtml and .xml are not set on the server, this
usually is easy to do from the control panel - unless you use a host
that will not allow this. The bottom line is that you need to serve a
true xhtml page for browsers that can handle it and an html page for
those such as IE that can not. This can be done, but it can involve
very careful design in the header exchange, code conversion from xhtml
to html, or perhaps using IE conditional comments to route IE to a
seperate html page, etc.

[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

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