Name

<script> — NN: 2, 3, 4 - MSIE: 2, 3, 4, 5 - HTML 4 - WebTV - Opera3

Synopsis

                     <script>...</script>
                  

Adds a script that is to be used in the document. See Chapter 22, for demonstrations of the use of the <script> tag.

Attributes

type=content type

Specifies the language of the script. Its value must be a media type (ex. text/javascript). This attribute is required by the HTML 4.0 specification and is a recommended replacement for the “language” attribute.

language= language

Identifies the language of the script, such as JavaScript or VBScript. This attribute has been deprecated by the HTML 4.0 Spec in favor of the “type” attribute.

src= url

Netscape only. Specifies the URL of an outside file containing the script to be loaded and run with the document.

Get Web Design in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.