<OBJECT> Tag & its Attribute
HTML Tag <OBJECT>
<OBJECT> Embeds a software object into a document. The object can be an ActiveX object, a Quick- Time movie, or any other objects or data that a browser supports. Use the <PARAM> tag to supply parameters to the embedded object. You can place messages and other tags between the <OBJECT> tags for browsers that do not support embedded objects.
Attribute of <OBJECT> Tag
- ALIGN
- BORDER
- CLASS
- CLASSID
- CODEBASE
- CODETYPE
- DATA
- DATAFLD
- DATASRC
- DECLARE
- HEIGHT
- HSPACE
- ID
- NAME
- SHAPES
- STANDBY
- TABINDEX
- TITLE
- TYPE
- USEMAP
- VSPACE
- WIDTH
ALIGN
Indicates how the embedded object lines up relative to the edges of the browser windows and/or other elements within the browser window.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 ALIGN=RIGHT>
Possible Values
LEFT, CENTER, RIGHT, TEXTTOP, MIDDLE, TEXTMIDDLE, BASELINE, TEXTBOTTOM, BASELINE
BORDER
Indicates the width (in pixels) of a border around the embedded object. BORDER=0 indicates no border.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 BORDER=10>
Possible Values
Any Integer Value.
CLASS
Indicates which style class applies to the element.
<OBJECT CLASS="dkm"
CODETYPE="application/x-msword">
</OBJECT>
Possible Values
Any Class Name.
CLASSID
Specifies the URL of an object resource.
<OBJECT
CLASSID="http://www.cs-tutorial.com/
quiz.class">
Possible Values
Any Class Name.
CODEBASE
Specifies the absolute or relative location of the base directory in which the browser will look for data and other implementation files.
<OBJECT CODEBASE="/code/">
</OBJECT>
Possible Values
URL
CODETYPE
Specifies the MIME type for the embedded object's code.
<OBJECT
CODETYPE="application/x-msword">
</OBJECT>
Possible Values
MIME Type.
DATA
Specifies the absolute or relative location of the embedded object’s data.
<OBJECT DATA="/video/demo.AVI">
</OBJECT>
Possible Values
URL
DATAFLD
Selects a column from a block of tabular data.
<OBJECT DATA="dataview.ocx"
DATASRC="#data_table"
DATAFLD="datafld1">
Possible Values
Field Name.
DATASRC
Specifies the location of tabular data to be bound within the document.
<OBJECT DATA="dataview.ocx"
DATASRC="#data_table">
Possible Values
Data Source Name.
DECLARE
Defines the embedded object without actually loading it into the document.
<OBJECT CLASSID="clsid:99B42120-6EC7-11CFA6C7-
00AA00A47DD3" DECLARE>
</OBJECT>
Possible Values
DECLARE
HEIGHT
Specifies the vertical dimension (in pixels) of the embedded object.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 VSPACE=10 HSPACE=10>
Possible Values
Value in Pixel or Percentage.
HSPACE
Specifies the size of the margins (in pixels) to the left and right of the embedded object.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 VSPACE=10 HSPACE=10>
Possible Values
Value in Pixel or Percentage.
ID
Indicates an identifier to associate with the embedded object. You can also use this to apply styles to the object.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 VSPACE=10 HSPACE=10
ID="swave2">
Possible Values
Any Id Name.
NAME
Specifies the name of the embedded object.
<OBJECT CLASSID="clsid:99B42120-6EC7-11CFA6C7-
00AA00A47DD3" NAME="Very Cool Thingie">
</OBJECT>
Possible Values
Any Name.
SHAPES
Indicates that the embedded object has shaped hyperlinks (that is, image maps).
<OBJECT DATA="navbar.gif" SHAPES>
Possible Values
SHAPES
STANDBY
Specifies a message that the browser displays while the object is loading.
<OBJECT
STANDBY="Please wait. Movie loading."
WIDTH=100 HEIGHT=250>
<PARAM NAME=SRC VALUE="TheEarth.AVI">
<PARAM NAME=AUTOSTART VALUE=TRUE>
<PARAM NAME=PLAYBACK VALUE=FALSE>
</OBJECT>
Possible Values
Any Text Message.
TABINDEX
Indicates the place of the embedded object in the tabbing order.
<OBJECT
CLASSID="clsid:99B42120-6EC7-11CF-A6C7-
00AA00A47DD3" TABINDEX=3>
</OBJECT>
Possible Values
Any Index Number.
TITLE
Specifies text assigned to the tag. You might use this attribute for context-sensitive help within the document. Browsers may use this to show tool tips over the embedded object.
<OBJECT
TITLE="Earth Movie" WIDTH=100
HEIGHT=250>
<PARAM NAME=SRC VALUE="TheEarth.AVI">
<PARAM NAME=AUTOSTART VALUE=TRUE>
<PARAM NAME=PLAYBACK VALUE=FALSE>
</OBJECT>
Possible Values
Any Text Message.
TYPE
Indicates the MIME type of the embedded object.
<OBJECT DATA="shocknew.dcr"
TYPE="application/x-director" WIDTH=288
HEIGHT=200 VSPACE=10 HSPACE=10>
Possible Values
MIME type.
USEMAP
Indicates the relative or absolute location of a client-side image map to use with the embedded object.
<OBJECT USEMAP="maps.html#map1">
Possible Values
URL
VSPACE
Specifies the size of the margin (in pixels) at the top and bottom of the embedded object.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 VSPACE=10 HSPACE=10>
</OBJECT>
Possible Values
Value in Pixel or percentage.
WIDTH
Indicates the horizontal dimension (in pixels) of the embedded object.
<OBJECT DATA="shocknew.dcr"
TYPE="application/director" WIDTH=288
HEIGHT=200 VSPACE=10 HSPACE=10>
Possible Values
Value in Pixel or Percentage.