HTMLEmbedElement: src 属性
HTMLEmbedElement 接口的 src 属性返回一个字符串,该字符串指示被嵌入资源的 URL。
它反映了 <embed> 元素的 src 属性。
值
字符串。
示例
html
<embed
id="el"
type="video/quicktime"
src="movie.mov"
width="640"
height="480"
title="Title of my video" />
js
const el = document.getElementById("el");
console.log(el.src); // Output: "movie.mov"
规范
| 规范 |
|---|
| HTML # dom-embed-src |
浏览器兼容性
加载中…