JavaScript Reference/Javascript Properties/dynsrc

Материал из Web эксперт
Перейти к: навигация, поиск

"dynsrc" Example

    
<html>
<body>
<script language="JavaScript">
function setSource() {
    document.all.myImage.dynsrc = "yourvideo.avi";
}
</script>
<img id="myImage" start="mouseover" alt="" width="200" height="200">
<button onclick="setSource();">Set Source</button>
</body>
</html>



"dynsrc" is applied to

+----------------+--------------------------------------------------------------+
| Applied_To     |<img>                           <input>                       |
|                |<input type="image">                                          |
+----------------+--------------------------------------------------------------+



"dynsrc" Syntax and Note

Note:
Read and write property. 
Specifies the URL of a video clip.
    
Syntax:
    
document.all.elementID.dynsrc = value