Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

language = javascript 1

Status
Not open for further replies.

Ineedjava

Technical User
Apr 14, 2001
21
US
If I use the code:

<Script language=javascript>

then what version of javascript does the browser default to? Should I assume that all versions (1.0 thru 1.3) of javascript are included in the latest IE or Netscape browser?
 
Hello Ineedjava,
The answer to your question is not exactly.
If you use <script language=&quot;javascript&quot;> you are telling to the browser that your script is written in javascript(obvsiouly).
If you add the version of javascript (ie: script language=&quot;javascript 1.1&quot; or javascript 1.3 you are telling to the browser what version of javascript are you using.
This is useful if you are writing some code for an specific version of the language.Since old browser doesn't support a particular version of javascript,if you specify one version,old browsers will ignore your code.

javascript 1.1:

Browsers lower than NS 3 and IE 4 will ignore the code (ie: NS 2, IE 3)


javascript 1.2

Browsers lower than NS 3 and IE 4 will ignore the code (ie: NS 2, IE 3)


javascript 1.3

for NS 4.5 and up. All other browsers will ignore the code.

I hope this helps.

Kindest Regards

alexfusion
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top