Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > Re: W3C Validator Errors

Reply
Thread Tools

Re: W3C Validator Errors

 
 
Jukka K. Korpela
Guest
Posts: n/a
 
      03-29-2009
wayne wrote:

> The W3C validator reports an error in the html:
> Line 17, Column 41: Attribute "language" exists, but can not be used
> for this element.


It's a poorly formulated error message. Unfortunately, they are making the
reports looser in their misguided attempt at being more user-friendly - and
they confuse users even more than before.

It is completely irrelevant that attribute "language" exists (according to
the DTD) for some element, when it does not exist (i.e. is not allowed) for
the element being investigated.

But I think you have dealt with this issue:

> <script type="text/javascript" language="JavaScript">
> Even though the "view source" clearly shows "language="javascript"" is
> not in the html.


Which "view source"? When I visit the page http://glenmeadows.us on a normal
browser and do View source, I surely see
<script type="text/javascript" language="JavaScript">
on line 17.

> I have changed the doctype dtd to several different types but always
> end up with the same results.


Why? Validation is about being exact with your syntax, not about throwing
random documents at a Molok-like demi-god called a Validator in order to be
lucky enough to please it and get a Sign of Approval (even though some W3C
policies may seem to encourage the latter view).

Do you really want to use XHTML 1.0 Strict? Why? Well, if you do, then deal
with the consequences. You have a lot to do then, and it's mostly nothing
productive. What's the point of getting rid of presentational attributes
when your source is full of presentational orientation? Things like that
<td class="white"><span class="smalltext">22</span></td>
are really just presentational markup, with <font> and everything, in
disguise.

If you have made the mistake of using XHTML in the first place, then you
could help yourself by using Transitional doctype - at least as the first
step, fixing real syntax errors if any, before proceeding to (futile?)
cleanup from Transitional to Strict.

> Other errors are also no in the html, almost like the validator is
> looking at a different page.
>
> The site is glenmeadows.us


Well, you gave a computer's Internet name (domain name), not a URL.

But are you sure _you_ are looking at http://gleanmeadows.us as a web page
and not at some file in some authoring program - a file from which the page
is constructed, possibly in a fairly complicated way?

--
Yucca, http://www.cs.tut.fi/~jkorpela/

 
Reply With Quote
 
 
 
 
asdf
Guest
Posts: n/a
 
      03-29-2009

"wayne" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed) m...
> Jukka K. Korpela wrote:
>> wayne wrote:
>>
>>> The W3C validator reports an error in the html:
>>> Line 17, Column 41: Attribute "language" exists, but can not be used
>>> for this element.

>>
>> It's a poorly formulated error message. Unfortunately, they are making
>> the reports looser in their misguided attempt at being more
>> user-friendly - and they confuse users even more than before.
>>
>> It is completely irrelevant that attribute "language" exists (according
>> to the DTD) for some element, when it does not exist (i.e. is not
>> allowed) for the element being investigated.
>>
>> But I think you have dealt with this issue:
>>

> Thank you for the response. Perhaps the error message is of little value
> here.
>>> <script type="text/javascript" language="JavaScript">
>>> Even though the "view source" clearly shows "language="javascript"" is
>>> not in the html.

>>
>> Which "view source"? When I visit the page http://glenmeadows.us on a
>> normal browser and do View source, I surely see
>> <script type="text/javascript" language="JavaScript">
>> on line 17.
>>

> As I've stated in response to the Richard and Andy, when I do a view
> source, the text at line 17 is not the same as what you see and I am
> looking in my browser, not the text you are seeing. The text in the error
> message does not show up at all in my browser, but when I click on show
> source in the W3C settings and look at that source, it is indeed there.
> There is cookie information there as well, which I don't see in my
> browser.
>
>>> I have changed the doctype dtd to several different types but always
>>> end up with the same results.

>>
>> Why? Validation is about being exact with your syntax, not about throwing
>> random documents at a Molok-like demi-god called a Validator in order to
>> be lucky enough to please it and get a Sign of Approval (even though some
>> W3C policies may seem to encourage the latter view).
>>

> The site is a cms driven site and the syntax is not easy to change.


That's weird. I thought a CMS was supposed to make this template-y stuff
*easier* rather than *harder* )

> There are hundreds of files to review and modify. I have been working on
> the site for a couple of years trying to remove the tables, but it is a
> daunting task.
>

[snip]


 
Reply With Quote
 
 
 
 
rf
Guest
Posts: n/a
 
      03-29-2009
wayne wrote:
> Jukka K. Korpela wrote:
>> wayne wrote:
>>
>>> The W3C validator reports an error in the html:
>>> Line 17, Column 41: Attribute "language" exists, but can not be used
>>> for this element.

>>
>> It's a poorly formulated error message. Unfortunately, they are
>> making the reports looser in their misguided attempt at being more
>> user-friendly - and they confuse users even more than before.
>>
>> It is completely irrelevant that attribute "language" exists
>> (according to the DTD) for some element, when it does not exist
>> (i.e. is not allowed) for the element being investigated.
>>
>> But I think you have dealt with this issue:
>>

> Thank you for the response. Perhaps the error message is of little
> value here.
>>> <script type="text/javascript" language="JavaScript">
>>> Even though the "view source" clearly shows "language="javascript""
>>> is not in the html.

>>
>> Which "view source"? When I visit the page http://glenmeadows.us on a
>> normal browser and do View source, I surely see
>> <script type="text/javascript" language="JavaScript">
>> on line 17.
>>

> As I've stated in response to the Richard and Andy, when I do a view
> source, the text at line 17 is not the same as what you see and I am
> looking in my browser, not the text you are seeing. The text in the
> error message does not show up at all in my browser, but when I click
> on show source in the W3C settings and look at that source, it is
> indeed there. There is cookie information there as well, which I
> don't see in my browser.


When I view source with FF and Chrome the script is not there. When I view
source with IE, Opera, Safari the script *is* there. Somebody methinks is
indulging in some server side browser sniffing.



>>> I have changed the doctype dtd to several different types but always
>>> end up with the same results.

>>
>> Why? Validation is about being exact with your syntax, not about
>> throwing random documents at a Molok-like demi-god called a
>> Validator in order to be lucky enough to please it and get a Sign of
>> Approval (even though some W3C policies may seem to encourage the
>> latter view).

> The site is a cms driven site and the syntax is not easy to change.
> There are hundreds of files to review and modify. I have been working
> on the site for a couple of years trying to remove the tables, but it
> is a daunting task.
>
>> Do you really want to use XHTML 1.0 Strict? Why? Well, if you do,
>> then deal with the consequences. You have a lot to do then, and it's
>> mostly nothing productive. What's the point of getting rid of
>> presentational attributes when your source is full of presentational
>> orientation? Things like that
>> <td class="white"><span class="smalltext">22</span></td>
>> are really just presentational markup, with <font> and everything, in
>> disguise.

>
>>
>> If you have made the mistake of using XHTML in the first place, then
>> you could help yourself by using Transitional doctype - at least as
>> the first step, fixing real syntax errors if any, before proceeding
>> to (futile?) cleanup from Transitional to Strict.
>>

> Perhaps I should cut my losses and stop trying to get rid of the
> errors. The php generated code does need a lot more work to get to
> 2009 standards.
>>> Other errors are also no in the html, almost like the validator is
>>> looking at a different page.
>>>
>>> The site is glenmeadows.us

>>
>> Well, you gave a computer's Internet name (domain name), not a URL.
>>

> Yes, I got lazy there as my browser inserts http:// automatically
> when I type a site into the address bar. I forget sometimes that I
> should include it when giving the url.
>
> I edit the site directly on the server using Quanta Plus and then view
> in Firefox through my isp. This works for me as I am sure my browser
> is seeing what others will see.
>
>> But are you sure _you_ are looking at http://gleanmeadows.us as a web
>> page and not at some file in some authoring program - a file from
>> which the page is constructed, possibly in a fairly complicated way?
>>

> The template for the page seems pretty straight forward, but other
> files are called from php and insert lines into the html. I would
> concede this is done in a complicated way as I cannot find the file that
> contains
> "language=javascript" in the directories.
>
> Thanks for taking the time to look at the site and for your
> advice/comments.



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: W3C Validator Errors Andy Dingley HTML 2 03-29-2009 11:21 PM
Re: W3C Validator Errors richard HTML 1 03-29-2009 06:32 PM
Problem with w3c validator in script definition of doPostBack Alfonso Alvarez ASP .Net 2 05-13-2004 07:47 AM
W3C Validator Icon and W3C Valdiator page Frank HTML 9 05-03-2004 09:32 AM
W3C Validator xeno HTML 1 06-28-2003 01:30 AM



Advertisments