"language=javascript" deprecated

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • drhowarddrfine
    Recognized Expert Expert
    • Sep 2006
    • 7434

    "language=javascript" deprecated

    When I visit this board, I see this frequently:
    Code:
    <script language=javascript>
    but "language=javas cript" was deprecated in 1996. So, why do people still use it? It doesn't do anything.
  • Logician
    New Member
    • Feb 2007
    • 210

    #2
    Originally posted by drhowarddrfine
    When I visit this board, I see this frequently:
    Code:
    <script language=javascript>
    but "language=javas cript" was deprecated in 1996. So, why do people still use it? It doesn't do anything.
    Because they don't know any better, they (or their teachers) are just copying outdated examples.

    Comment

    • acoder
      Recognized Expert MVP
      • Nov 2006
      • 16032

      #3
      Yes, people just copy code. We have this same problem with document.all and document.layers and other forms of outdated browser detection techniques.

      Instead of language=javasc ript, use type="text/javascript", see link (for the benefit of anyone who doesn't know)

      Comment

      Working...