Click to Rate and Give Feedback
Properties
 src Property
SRC Attribute | src Property
Note: This documentation is preliminary and is subject to change.

Retrieves the URL to an external file that contains the source code or data.

Syntax

HTML<SCRIPT SRC = sURL... >
Scripting[ sURL = ] SCRIPT.src

Possible Values

sURLString that specifies or receives the URL of the source code or data.

The property is read/write. The property has no default value.

Expressions can be used in place of the preceding value(s), as of Microsoft® Internet Explorer 5. For more information, see About Dynamic Properties.

Remarks

The SRC attribute was first available in Microsoft Internet Explorer 3.022. The src property is exposed through the object model as of Internet Explorer 4.0.

In Internet Explorer 5 and greater, the SRC attribute of the script element can refer to an XML data set if the LANGUAGE attribute is set to XML.

A script can contain an external reference as well as code within the block. The code specified by the src property precedes the code contained within the document.

Standards Information

This property is defined in HTML 4.0 World Wide Web link and is defined in World Wide Web Consortium (W3C) Document Object Model (DOM) Level 1 World Wide Web link.

Applies To

SCRIPT
Tags What's this?: Add a tag
Community Content
 
Add Community Content
© 2008 Microsoft Corporation. All rights reserved. Terms of Use  |  Trademarks  |  Privacy Statement
Page view tracker