English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
The align attribute specifies the alignment of the <object> element based on the surrounding elements, the <object> element is an inline element (it does not insert a new line on the page), which means that text and other elements can wrap around it. Therefore, specifying the alignment of <object> based on surrounding elements may be very useful.
A left-aligned <object>:
<!DOCTYPE html> <html> <head> <title>HTML:<object> align attribute - Basic Tutorial Website (oldtoolbag.com)</title> </head> <body> <h4>Object with align="left":</h4> <p>This is some text. <object width="200" height="200" align="left" data="bookmark.swf"></object> This is some text.</p> <p>This is some text. This is some text.</p> </body> </html>Test see ‹/›
IEFirefoxOperaChromeSafari
All major browsers support the align attribute.
HTML5 does not support the <object> align attribute. Please use CSS instead.
In HTML 4.01, the align attribute of <object> has been deprecated.
L'attributo align specifica lo stile di allineamento dell'elemento <object> in base agli elementi circostanti.
L'elemento <object> è un elemento inline (non inserisce una nuova riga nella pagina), il che significa che il testo e gli altri elementi possono circondarlo. Pertanto, specificare lo stile di allineamento di <object> in base agli elementi circostanti può essere utile.
In HTML 4.01, l'attributo align dell'<object> è obsoleto. Utilizzare CSS invece.
Sintassi CSS: <object style="float:right">
CSS Esempio: Flottare a destra un <object>
Nel nostro tutorial CSS, vedrete di più su Proprietà float dettagli.
<object align="left|right|middle|top|bottom">
Valore | Descrizione |
---|---|
left | Allineamento verso sinistra degli oggetti. |
right | Allineamento verso destra degli oggetti. |
middle | Allineamento centrale degli oggetti. |
top | Allineamento verso l'alto degli oggetti. |
bottom | Allineamento verso il basso degli oggetti. |