Producing web pages
* HTML CSS DHTML XHTML A to Z of tags        Accessibility          Design

<object>

<object
archive=cdata
align=left|texttop|middle|textmiddle|
baseline|textbottom|center|right

border=n
classid=url
class=type
codebase=url
codetype=codetype
data=url
declare
dir=ltr|rtr
height=n
hspace=n
id=value
lang=language
name=url
shapes
standby=message
style=style
tabindex=n
title=text
type=type
usemap=url
vspace=n
width=n
</object>

Inserts an object, such as a picture, document, applet, or Active-X control, into the HTML page. An object can contain any tags ordinarily used within the body of an HTML page, including section headings, paragraphs, lists, forms, and nested objects.

The end-tag is required.

Attributes

archive=cdata

Specifies a comma-separated list of archived files (either absolute URIs or URIs relative to the codebase), allowing the browser to download many files with a single connection and hence decreasing the total download time.

align=left|texttop|middle|textmiddle|
baseline|textbottom|center|right

Sets the alignment for text surrounding the object. The default is left.

Value…

Description…

left

The object is drawn as a left-flush "floating object," and text flows around it

texttop

Surrounding text is aligned with the top of the object

middle

The object is drawn as a middle-centred "floating object," and text flows around it

textmiddle

Surrounding text is aligned with the middle of the object

baseline

The object is drawn with its bottom aligned with the baseline of the continuous text

textbottom

Surrounding text is aligned with the bottom of the object

center

Surrounding text is aligned with the centre of the object

right

The object is drawn as a right-flush "floating object," and text flows around it

border=n

The width of the border if the object is defined to be a hyperlink.

classid=url

Identifies the object implementation. The syntax of the url depends on the object type. For example, the syntax is CLSid:class-identifier for registered ActiveX controls.

class=type

Indicates the class to which the tag belongs. You can use the class attribute in a style sheet to create different styles that you want apply to a single HTML tag. For example, you might create three different styles for a heading <hn> tag. See Using the class attribute as a selector for more details.

codebase=url

Identifies the code base for the object. The syntax of the url depends on the object.

codetype=codetype

Specifies the Internet media type for code.

data=url

Identifies data for the object. The syntax of the url depends on the object.

declare

Declares the object without instantiating it. Use this when creating cross-references to the object later in the page or when using the object as a parameter in another object.

dir=ltr|rtr

Specifies the direction of text. This can be left-to-right (ltr) or right-to-left (rtl). For example, English characters are presented left-to-right, Hebrew characters are presented right-to-left.

height=n

Specifies the suggested height for the object.

hspace=n

Specifies the horizontal gutter. This is the extra, empty space between the object and any text or pictures to the left or right of the object.

id=value

Specifies a unique name for the tag. No two tags can have the same id on a single page. The value must begin with a letter followed by any alphanumeric character, a hyphen, an underscore, a colon or a full stop. You use it to reference a unique style for a tag or to manipulate the tag with a script.

lang=language

Specifies which language the <object> tag uses. You can enter any valid ISO standard language abbreviation, for example, “en” for English, “de” for German and so on. For example, <span lang="es">hola! como esta?</span>.

This attribute helps search engines understand different languages as different languages rather than just misspelled English. It may also help spelling and grammar checkers and allow speech synthesizers to use language-dependent pronunciation rules.

name=url

Sets the name of the object when submitted as part of a form.

shapes

Specifies that the object has shaped hyperlinks.

standby=message

Sets the message to show while loading the object.

style=style

Specifies style information. See Style sheets for more information.

tabindex=n

Sets the position of the object in the tabbing order.

title=text

For information only. Some browsers display the title when you move the mouse over the tag (like a tool tip).

type=type

Specifies the Internet media type for data.

usemap=url

Specifies the image map to use with the object.

vspace=n

Specifies the vertical gutter. This is the extra, empty space between the object and any text or pictures above or below the object.

width=n

Specifies the suggested width for the object.