-
Notifications
You must be signed in to change notification settings - Fork 22.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add docs for
HTMLEmbedElement.src
(#33553)
* add docs * fix
- Loading branch information
1 parent
736da09
commit a0460b9
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
--- | ||
title: "HTMLEmbedElement: src property" | ||
short-title: src | ||
slug: Web/API/HTMLEmbedElement/src | ||
page-type: web-api-instance-property | ||
browser-compat: api.HTMLEmbedElement.src | ||
--- | ||
|
||
{{APIRef("HTML DOM")}} | ||
|
||
The **`src`** property of the {{domxref("HTMLEmbedElement")}} interface returns a string that indicates the URL of the resource being embedded. | ||
|
||
It reflects the `src` attribute of the {{HTMLElement("embed")}} element. | ||
|
||
## Value | ||
|
||
A string. | ||
|
||
## Examples | ||
|
||
```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" | ||
``` | ||
|
||
## Specifications | ||
|
||
{{Specifications}} | ||
|
||
## Browser compatibility | ||
|
||
{{Compat}} |