Jump to content

What doctype do I use?


Cory94bailly

Recommended Posts

Ok my site is http://etsoldiers.com/massattack

 

http://validator.w3.org/check?uri=http%3A%2F%2Fetsoldiers.com%2Fmassattack%2F&charset=(detect+automatically)&doctype=Inline&outline=1&group=1&No200=1&verbose=1&st=1&user-agent=W3C_Validator%2F1.606

 

 

I have tried I think every doctype and it's giving me 'different' errors on the validator and each messes up something different for the design.

 

Any help?

Link to comment
Share on other sites

You can't have comments, spaces, tabs or anything at all before your doctype, or it invalidates the doctype. So you need to take out those doctypes you aren't using, as right now it is the same as if you were not using a doctype.

 

I took those out and it seems the same for the client and the validator...

 

If you access it on the web, it seems to move the pictures or something, it's annoying.. (If I take out the doctype, it fixes it.)

Link to comment
Share on other sites

Well of course it will be different - your code is being evaluated with no doctype now, so it's guessing how it should be displayed. You have managed to tweak those guesses into a site that works (at least in one browser). When you add a doctype, now it has an actual set of rules, so it's going to display the site the way your code says its displayed. Since your code is tweaked to work with errors, its not going to display right when using a proper set of rules. So you will have to fix your code after adding a doctype. Step one - get rid of all the errors that the validator is throwing up.

 

As for what doctype to use, use html 4.01 strict or transitional, either one. You are using a frameset doctype now, but you aren't using frames (which is a good thing), so you shouldn't use that doctype.

 

You also have a space before your doctype. As I mentioned before, you cannot have ANYTHING before your doctype (except php code).

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  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.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.