...

View Full Version : Validation Problem



cadfan
04-12-2009, 10:05 AM
Have had my webpage validated and had two warnings. Could someone tell me why because i can't figure out what i've done wrong. I get the following message:

This document was Tentatively checked as XHTML 1.0 Strict tentatively passed; 2 warning(s)

No Character encoding found! Falling back to utf-8.

No Character encoding found at document level.

The Doctype and Character set i have used are below.


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<body>
</body>
</html>

Thanks in advance

djm0219
04-12-2009, 02:45 PM
The W3C recommended (http://www.w3.org/QA/2002/04/valid-dtd-list.html) template for a XHTML strict document shows that your xmlns line should read:


<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

cadfan
04-12-2009, 03:53 PM
Hiya DJM

Have taken your advice but when validated it still comes back with:

This document was Tentatively checked as XHTML 1.0 Strict
Tentatively passed 2 warnings.

No Character encoding found! Falling back to utf-8
No Character encoding declared at document level

Thanks for taking the time out to reply

djm0219
04-12-2009, 03:56 PM
Are these 2 lines



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

all on one line in your document?


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

Do you have a link to the page in question available?

cadfan
04-13-2009, 08:36 AM
Hi DJM

Unfortunately the webpage is not online at the moment but i have typed the doctype exactly as it appears on the webpage below:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

I really appreciate all the help and advice i have received at the CodingForums but i am now beginning to think that the validation process is just a time waster especially when you take into account that it is not actually needed for a webpage/site to appear on line. I have gone over the doctype looking for any errors of which i can find none! If anyone can point out an error that i may have over looked please let me know as i would be more than happy to rectify it. Big thanks

cadfan
04-13-2009, 09:03 AM
Finally!!

I have finally managed to have my webpage validated without any warnings.
YIPPEE!

djm0219
04-13-2009, 12:38 PM
I really appreciate all the help and advice i have received at the CodingForums but i am now beginning to think that the validation process is just a time waster especially when you take into account that it is not actually needed for a webpage/site to appear on line.

It is certainly NOT a time waster. Validating your pages ensures that your visitors will have a consistent experience no matter what browser they are using. You're doing them, and yourself, a dis-service if you don't create valid pages IMO.

In a later post you said you resolved the problem. What did you find/do that resolved it so that others might benefit from this thread?

cadfan
04-13-2009, 12:59 PM
You are of course correct when you say validation is not a time waster. Was just me letting off a little steam because i could not see the error what was staring me in the face.

The error was that i had added an (s) when i shouldn't have and made the meta tag read:

<meta http-equiv="Contents-Type"

So my advice to anyone in a similar position is check, and recheck your spelling at all times to rule out an error like the one i had.

djm0219
04-13-2009, 01:35 PM
Ah, it's always the littlest and simplest things that bite us in the arse :)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum