"language=Javascript" -- not validating

Discussion in 'HTML' started by TheKeith, Oct 19, 2003.

  1. TheKeith

    TheKeith Guest

    Why is this not validating properly? Is this excluded from the html 4.01
    spec? Should I just use <script type="text/javascript"> without the language
    attribute? Thanks.
    TheKeith, Oct 19, 2003
    #1
    1. Advertising

  2. TheKeith

    Adrienne Guest

    Gazing into my crystal ball I observed "TheKeith" <> writing
    in news::

    > Why is this not validating properly? Is this excluded from the html
    > 4.01 spec? Should I just use <script type="text/javascript"> without
    > the language attribute? Thanks.
    >
    >
    >


    Yes.

    --
    Adrienne Boswell
    Please respond to the group so others can share
    http://www.arbpen.com
    Adrienne, Oct 19, 2003
    #2
    1. Advertising

  3. TheKeith

    TheKeith Guest

    "Adrienne" <> wrote in message
    news:Xns9418E9FDEC0Carbpenyahoocom@207.115.63.158...
    > Gazing into my crystal ball I observed "TheKeith" <> writing
    > in news::
    >
    > > Why is this not validating properly? Is this excluded from the html
    > > 4.01 spec? Should I just use <script type="text/javascript"> without
    > > the language attribute? Thanks.
    > >
    > >
    > >

    >
    > Yes.


    thanks
    TheKeith, Oct 19, 2003
    #3
  4. TheKeith

    brucie Guest

    In post <>
    TheKeith said...

    > [ "language=Javascript" ]
    > Why is this not validating properly?


    language = cdata [CI]
    Deprecated. This attribute specifies the scripting language of the
    contents of this element. Its value is an identifier for the language,
    but since these identifiers are not standard, this attribute has been
    deprecated in favor of type.

    > Is this excluded from the html 4.01 spec?


    yes

    <!ELEMENT SCRIPT - - %Script; -- script statements -->
    <!ATTLIST SCRIPT
    charset %Charset; #IMPLIED -- char encoding of linked resource --
    type %ContentType; #REQUIRED -- content type of script language --
    src %URI; #IMPLIED -- URI for an external script --
    defer (defer) #IMPLIED -- UA may defer execution of script --
    >


    > Should I just use <script type="text/javascript"> without the language
    > attribute?


    yes

    type = content-type [CI]
    This attribute specifies the scripting language of the element's
    contents and overrides the default scripting language. The scripting
    language is specified as a content type (e.g., "text/javascript").
    Authors must supply a value for this attribute. There is no default
    value for this attribute.

    18.2.1 The SCRIPT element
    http://www.w3.org/TR/html401/interact/scripts.html#h-18.2.1

    --
    brucie.
    19/October/2003 05:13:49 pm
    brucie, Oct 19, 2003
    #4
  5. In article <>, says...
    > Why is this not validating properly? Is this excluded from the html 4.01
    > spec? Should I just use <script type="text/javascript"> without the language
    > attribute? Thanks.
    >

    Would it not have been worth trying, just to see if your hunch was
    correct?

    --
    Hywel I do not eat quiche
    http://hyweljenkins.co.uk/
    http://hyweljenkins.co.uk/mfaq.php
    Hywel Jenkins, Oct 19, 2003
    #5
  6. TheKeith

    Richard Guest

    Yes would be sufficient.
    Richard, Oct 19, 2003
    #6
  7. TheKeith

    Richard Guest

    Hywel Jenkins wrote:

    > In article <>, says...
    >> Why is this not validating properly? Is this excluded from the html
    >> 4.01
    >> spec? Should I just use <script type="text/javascript"> without the
    >> language
    >> attribute? Thanks.


    > Would it not have been worth trying, just to see if your hunch was
    > correct?


    Heaven forbid! That requires thought!
    "I think, therefor I am not a politician."
    Richard, Oct 19, 2003
    #7
  8. Hywel Jenkins, Oct 19, 2003
    #8
  9. TheKeith

    TheKeith Guest

    "Richard" <anom@anom> wrote in message news:...
    > Hywel Jenkins wrote:
    >
    > > In article <>, says...
    > >> Why is this not validating properly? Is this excluded from the html
    > >> 4.01
    > >> spec? Should I just use <script type="text/javascript"> without the
    > >> language
    > >> attribute? Thanks.

    >
    > > Would it not have been worth trying, just to see if your hunch was
    > > correct?

    >
    > Heaven forbid! That requires thought!
    > "I think, therefor I am not a politician."


    I did that first smart ass, but I wasn't sure if it might cause some
    unforeseen problems.
    TheKeith, Oct 19, 2003
    #9
  10. TheKeith

    cwdjr Guest

    Yes, for a new page, you should only use "type" and not "language"
    instead of or in addition to "type". I believe that in html 3.2 you
    could use script alone, although many added language. With html 4 use
    of type became required to validate at the W3C html validator as
    html4. The last time I checked, you could add language in addition to
    type at html 4.01 transitional, but I have not validated at this level
    for so long that things could have changed. I do know that use of
    language in the script tag, even when type is present, gets you a
    validation error in xhtml 1.1. I think use of language in the script
    tag in addition to type also is taboo at xhtml 1.0 strict, but again I
    have not checked this in a long time. JS has been used many years now,
    and many write it and the script tag as they learned it several years
    ago. Many current browsers still accept the older ways of doing
    things. I have seen large commercial site codes that have had much new
    code added over several years. In them you sometimes find a mix of
    script tags that use all possibe combinations of script, language, and
    type that have been used over the years.
    cwdjr, Oct 19, 2003
    #10
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. JV
    Replies:
    4
    Views:
    2,944
  2. =?Utf-8?B?U3RldmUgQnVnZGVu?=

    dynamic form not validating on server

    =?Utf-8?B?U3RldmUgQnVnZGVu?=, Feb 28, 2006, in forum: ASP .Net
    Replies:
    5
    Views:
    1,326
    andrea
    Feb 28, 2006
  3. Ben Jessel
    Replies:
    0
    Views:
    391
    Ben Jessel
    Aug 5, 2004
  4. Robert Maas, see http://tinyurl.com/uh3t

    Idea for auto-validating text field, done already or not?

    Robert Maas, see http://tinyurl.com/uh3t, Jun 11, 2005, in forum: Java
    Replies:
    4
    Views:
    429
    Dale King
    Jun 28, 2005
  5. TheKeith
    Replies:
    9
    Views:
    1,145
    Leif K-Brooks
    Oct 22, 2003
Loading...

Share This Page