Jump to content

Strict vs Transitional CLOSED with thanks in the last post


niche

Recommended Posts

The pros to Transitional: No need to worry about CSS, you can just use HTML attributes to style everything. iframes are allowed in Transitional which are usually good in web applications.The pros to Strict: The W3C recommends it. The pros to HTML 5: It allows you to use iframes and at the same time is supported by the W3C and will continue to be supported for a whole long time. I recommend using HTML 5 from now on.

Link to comment
Share on other sites

The pros to Transitional: No need to worry about CSS, you can just use HTML attributes to style everything.
I don't consider that a pro. When I see that sort of thing I consider it a mess. CSS was created for a reason. Transitional allows for a lot of sloppy coding practices. The only real benefit I see with Transitional is the iframes, but as you mentioned, those are allowed in HTML 5 so there is absolutely no reason to use Transitional. Strict, AFAIK, provides better cross-browser support than Transitional. Strict also forces you to be more disciplined with your coding practices, which is always a good thing. I think HTML 5 also enforces a lot of the same rules, but lifts others, like the self closing tags (they are optional now). Personally, I wish the self-closing tags were still required, because I think this:
<img src='something.jpg' alt='something'>

is sloppy and confusing. It's an opening tag with no closing tag. EDIT: I just remembered that the self-closing tags are XHTML not HTML. Either way, I still wish they were required.

Edited by ShadowMage
Link to comment
Share on other sites

Guest So Called

I switched to 4.01 strict a few years ago. It's working satisfactorily for me and I do not expect to change anytime soon.

Link to comment
Share on other sites

I've been using HTML 4.01 Strict until a majority of browsers supported HTML 5. I don't see an actual need for the /> on self-closing tags. It's not really a bad practise, in HTML 4.01 the validator gives a warning if you use them.

Link to comment
Share on other sites

Guest So Called
I don't see an actual need for the /> on self-closing tags.
It sounds a bit obsessive compulsive. It's not like browsers require it. It satisfies somebody's sense of neatness.
Link to comment
Share on other sites

Guest So Called

In a way it sort of satisfies my own sense of neatness. I don't mind the < ... /> tags.

Edited by So Called
Link to comment
Share on other sites

Thanks for everyone's help on this topic especially Ingolme, Shadow Mage, So Called, and justsomeguy.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...