You are not logged in.

#1 2008-07-20 14:35:41

Abelian
Member
Registered: 2008-04-23
Posts: 63

Xhtml/html

As far as I was aware, HTML was dated and XHTML was the up and coming standard that you shoud learn. However, recently I have started to see things such as this http://hixie.ch/advocacy/xhtml which suggest that XHTML is not handled properly by browsers and you should just use HTML instead.

What should I use?

Offline

#2 2008-07-20 18:42:09

Varreon
Member
Registered: 2008-07-03
Posts: 95

Re: Xhtml/html

I do all my web-development with xhtml. I wasn't aware of these issues, but all the big browsers(opera, firefox, ie, safari) seem to work fine with xhtml. If you are worried about flawed viewing, browsershots.org is perfect to assure you that it works.

Offline

#3 2008-07-20 22:16:23

celthias
Member
Registered: 2008-04-15
Posts: 83

Re: Xhtml/html

As XHTML is just an application of XML, I'd recommend it over HTML these days. With its DTD, it doesn't let you get away with any mistakes, and forces you to write semantically better markup. I think (punch me if im wrong) that XHTML tends to encourage the use of CSS, so the website can become a little more modular, with the XHTML forming the structure of the page and CSS handling the aesthetics. I don't know how true any of this is but, mostly just imho tongue

Offline

#4 2008-07-20 22:53:11

Bebo
Member
From: Göteborg, Sweden
Registered: 2006-06-07
Posts: 207

Re: Xhtml/html

As I understand it, it's the Strict DTD:s that promote the use of CSS, not XHTML in itself (see Transitional vs. Strict Markup).

I've yet to see a website that actually serves the correct mimetype while posing as being XHTML - all I've checked serves their pages as text/html. I used to write my webpages with XHTML as my doctype, and when I read the "Sending XHTML as text/html Considered Harmful" article a few years ago I noticed that I too were serving them as text/html. It took me a good while to figure out how I could serve the pages as application/xhtml+xml (I vaguely remember that I had to do it with some php or even apache setting - it could not be done in the pages themselves...), and when I finally succeeded my webpages... well, I got lots of error messages, and when they worked they were slow as hell, even though it was just markup and css, and no javascript.

So, I (try to) stick to HTML 4.01 Strict smile

Offline

#5 2008-07-21 14:21:00

Abelian
Member
Registered: 2008-04-23
Posts: 63

Re: Xhtml/html

Bebo wrote:

As I understand it, it's the Strict DTD:s that promote the use of CSS, not XHTML in itself (see Transitional vs. Strict Markup).

I've yet to see a website that actually serves the correct mimetype while posing as being XHTML - all I've checked serves their pages as text/html. I used to write my webpages with XHTML as my doctype, and when I read the "Sending XHTML as text/html Considered Harmful" article a few years ago I noticed that I too were serving them as text/html. It took me a good while to figure out how I could serve the pages as application/xhtml+xml (I vaguely remember that I had to do it with some php or even apache setting - it could not be done in the pages themselves...), and when I finally succeeded my webpages... well, I got lots of error messages, and when they worked they were slow as hell, even though it was just markup and css, and no javascript.

So, I (try to) stick to HTML 4.01 Strict smile

That is what I have gathered having read around this last day. You would of thought that it would have been more publicised - IE7 can't handle application/xhtml at all and asks you to download that page. Anything else is just malformed HTML. Wierd. Back to brushing up on the HTML skills then....

Offline

#6 2008-07-21 16:42:55

catwell
Member
From: Bretagne, France
Registered: 2008-02-20
Posts: 207
Website

Re: Xhtml/html

I don't care about IE and just use application/xhtml. Maybe dynamic websites could use a trick to detect the user agent and change accordingly (text/html for IE and application/xhtml for the rest), but I think the users should just use another browser until Microsoft fixes IE's behaviour.

Of course that reasoning won't work for commercial websites...

Offline

#7 2008-07-22 01:26:23

Lyceuhns
Member
From: João Pessoa, Paraíba, Brasil
Registered: 2008-05-09
Posts: 121

Re: Xhtml/html

XHTML 1.0 Strict
o/

Offline

Board footer

Powered by FluxBB