Jump to content

"no doctype found..."


Oso Polar
 Share

Recommended Posts

The wrong is that HTML 4 doesn't have a frameset doctype to begin with. It only has "loose" (a.k.a. transitional) and strict. XHTML 1.0 does come in frameset, transitional and strict though.Here's the doctype for loose HTML 4, if you are really sure you want to use it:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

[edit] OMG! It seems there IS actually a framest version of HTML 4. Hmm.... just a sec. [/edit][edit] This is the URI I found at the HTML 4 specification:

http://www.w3.org/TR/1999/REC-html401-19991224/frameset.dtd

and this one below it as an entity reference or whatever:

http://www.w3.org/TR/html401/frameset.dtd

Try replacing your with some of theese.One advice though. Why use HTML anyway? Why don't you go with XHTML 1.0 (at first) instead?[/edit]

Edited by boen_robot
Link to comment
Share on other sites

I'll try those :) And why html... well, actually, I don't really know. I wanted to built a website, and I was told I had to do that with html... so I learned some things from w3schools and made a site...what's the problem with html that xhtml doesn't have?

Link to comment
Share on other sites

XHTML is more strict when it comes to structure rules. Many tags from HTML are depreciated in XHTML because W3C wants to seperate strucute from presentation. Many things people use to do in HTML is now handled by XHTML and CSS.By seperating structure from presentation it makes the pages more managable and makes changes quicker and easier.

Link to comment
Share on other sites

well I do use css for the real presentation stuff :) I guess there's a lot more to do for me if I really wanted to seperate structure from presentation... but I'm not doing all the fonts and colors in html :)

Chances are you could switch to XHTML and see very little diffrence.
Link to comment
Share on other sites

Change your doctype to a XHTML doctype and then try and validate it. that is the best place to start. THis will show where you need to make changes to your code.Just post any question you have here if you run into trouble :)

Link to comment
Share on other sites

There's the XHTML tutorial at W3Schools which basically explains just that, but in short:Use XHTML's doctype. At first, I suggest you try XHTML transitional until you get used to the new rules. It's DTD:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

And when you don't need to use any presentational attribute and really don't need to use deprecated elements anymore, you should switch to XHTML strict. Instead of using XHTML 1.0 Stric however, I would suggest that you use 1.1 instead:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

Besides that, you must close empty elements with a forward slash at the end. Example:<br />, <hr />, <img />, etc.Write tags and attributes in lowercase.Any other differences I might have forgotten are listed in the XHTML tutorial above.

Link to comment
Share on other sites

I always use to use XHTML 1.1 and then people told me not becuase IE doesn't read it correctly(if implemented 100% correct). So I dropped to 1.0 strict. But that only applies if you don't send 1.1 as text/html but as xml/application or something.Apparently it violates the specs, but I never understood that becuase it validates correctly. Anyways I am slowly switching back to 1.1 anyways.

Link to comment
Share on other sites

But that only applies if you don't send 1.1 as text/html but as xml/application or something.

MSIE is getting confused somehow with application/xhtml+xml and application/xml (if I remember correct?),but try text/xml, I think it should work better with MSIE and it can be used with XHTML 1.1Look what W3C says:http://www.w3.org/TR/xhtml-media-types/#summary
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
 Share

×
×
  • Create New...