The embed
element is a non-standard element that is used
to embed multimedia content into a webpage.
Often, the multimedia content will require browser plugins like
Flash Player, QuickTime Player etc.
The embed
element is not part of any current
(X)HTML standard except the unfinalized HTML 5. The recommended element
for embedding media objects is the object
element, which
is part of the HTML 4.01 and XHTML 1.0 Standard.
The embed
element can have a block or inline parent element.
Attributes
align
- This attribute can take the values
left
,right
,top
andbottom
. However, it is perferable to use CSS instead of this attribute. height
andwidth
- Specifies the height and width of the element. It is perferable to use CSS instead of these attributes.
name
andid
- These attributes specify a name for the embedded object. However, it is better
to use only the
id
attribute becausename
is deprecated in XHTML. hidden
- This attribute can take the values
yes
orno
. A value ofyes
hides the object. This is not a well supported attribute and must therefore be avoided. pluginspage
- The value of this attribute is a URL of a page that contains instructions on how to download and install the plugin required to render the embedded content. This attribute is obsolete.
hspace
andvspace
- These attributes were used to specify the amount of horizontal and vertical space that should be left clear of the embedded object. It is preferable to use CSS instead of these attributes.
src
- The value of this attribute is the URL of the file or object to be embedded.
type
- The value of this attribute is the MIME type of the embedded object. However,
the browser can also determine the type of object by the file extension of the file
specified by
src
or by the header sent by the server when the object is accessed.
HTML 5 allows any other attributes that are specific to the kind of object embedded.
The noembed
Element
This is a nonstandard child element of the embed
element. It contains
text, images or objects that are displayed when the embedded object cannot be displayed.
No comments:
Post a Comment