Missing attribute in a <script> element (Was: Re: [VE][127] Add Subject Here)

Eglitz Multimedia Solution Provider wrote:

> how can i remove this eror "
> <script language="JavaScript" src="bg.js"></script>"
> from my site
> Validating http://www.hotelndeal.com/
> Error [127]: "required attribute X not specified"

By adding the required attribute. The document type definition specifies 
that the type="..." attribute is required for a <script> element.

As far as the validator is concerned, any value will do, since the 
attribute is declared with a CDATA value. In practice, people use 
type="text/javascript", which is recognized by all relevant browsers. 
According to RFC 4329 ( http://www.faqs.org/rfcs/rfc4329.html ), that 
value is obsolete; in reality, the preferred "application/javascript" 
may have more limited browser support.


Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/ 

Received on Friday, 13 June 2008 06:36:01 UTC