Jump to content
Killersites Forums

Transitional to Strict


youngros
 Share

Recommended Posts

When I first got to grips with hand coding and being told it had to validate, I used XHTML. Well that was what I was told to use, and it is also the default of DW8.

My sites now all validate XHTML transitional, but I want them to validate strict. I figure it is probably easier to go with XHTML strict than HTML strict.

Some of the errors are easy enough to correct, removing "target". But how do I go about changing the "align" attribute within a table?

Link to comment
Share on other sites

Thanks Susie, that should help.

 

I have read the article before, and so wish I had stuck to HTML, but maybe easier to carry on as I am, but make it strict or go for XHTML1.1

 

To get the strict on my site (or some of it) I had to remove the border "0" from the weather link.

 

ww w.holy trinity-mad eira.org/ It has now put a purple border on the link. Can this be removed using CSS?

Edited by youngros
Link to comment
Share on other sites

XHTML 1.1 is just Strict (no transitional) and should use content="application/xhtml+xml" instead of content="text/html", but then IE6 has serious problems.

 

If you use XHTML 1.0 with content="text/html" then that's tag soup and back to plain HTML.

 

For your purple image border, put in img { border: none; } to get rid of link state border colors in the whole website.

Link to comment
Share on other sites

...but maybe easier to carry on as I am, but make it strict or go for XHTML1.1

 

XHTML 1.1 is just Strict (no transitional) and should use content="application/xhtml+xml" instead of content="text/html", but then IE6 has serious problems.

 

Wickham is of course right... but to qualify it...

 

Not just IE6 has problems, no version of IE supports XHTML, nor has I seen claims that IE8 will. This means you will have to use content negotiation (see my article) in order to serve XHTML to all browsers but IE and HTML to IE, otherwise IE will try to download the page. Also, if you or the owner/maintainer of the web site makes one little mistake like forgetting to encode an ampersand (&) or your editor transforms it when you update a page... the page will not load, the user will see a while sheet with a cryptic red XML error message telling them you screwed up. Of course more things can sink the site than just an "&". If it is a site page it is irritating, but if it happens on a category or worse case, the index page, your sunk. It happened often to me on LSW, a small mistake in a new feed page, well that mistake would be inserted into the index page slice of the latest articles and the index page would not open. I could not even enter to correct the problem and had to jump through hoops trying to correct it.

 

XHTML 1.1 is not worth it because it must be served as

content="application/xhtml+xml"

Link to comment
Share on other sites

Use just HTML 4.01 (soon to be upgraded to HTML 5.0).

 

The problem is that major browsers are so forgiving and flexible, they guess when they meet a problem. There's another post on this forum which I answered today which used XHTML 1.1 (and didn't have any content type meta tag) and it worked without the XHTML 1.1 having any effect, and no effect when I added content="text/html", because it just treats it all as HTML, but it's not correct!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...