RAD Studio (Common)
ContentsIndex
PreviousUpNext
IMG HTML Element

The IMG element embeds an image or a video clip in the document and provides the following attributes and events.

Item 
Description 
align  
Specifies the horizontal alignment of its element with respect to the surrounding context. Possible values are left, right, center, and justify.  
alt  
For user agents that cannot display images, forms, or applets, this attribute specifies alternate text. The language of the alternate text is specified by the lang attribute.  
border  
Specifies the width of an image border, in pixels.  
class  
Assigns a class name or set of class names to an element. Any number of elements may be assigned the same class name or names. Multiple class names must be separated by white space characters.  
dir  
Specifies the direction of directionally neutral text in an element's content and attribute values:
ltr indicates left-to-right text or table.
rtl indicates right-to-left text or table.  
height  
Specifies the image and object height override.  
hspace  
Specifies the amount of white space to be inserted to the left and right of an image.  
id  
Assigns a name to an element. This name must be unique in a document.  
ismap  
For the IMG and INPUT elements, associates a server-side image map with the element.  
lang  
Specifies the base language of an element's attribute values and text content. The default value of this attribute is unknown.  
longdesc  
Specifies a link to a long description of the image.  
name  
Assigns the control name.  
onclick  
The onclick event occurs when the pointing device button is clicked over an element.  
ondblclick  
The ondblclick event occurs when the pointing device button is double clicked over an element.  
onkeydown  
The onkeydown event occurs when a key is pressed down over an element.  
onkeypress  
The onkeypress event occurs when a key is pressed and released over an element.  
onkeyup  
The onkeyup event occurs when a key is released over an element. This attribute may be used with most elements.  
onmousedown  
The onmousedown event occurs when the pointing device button is pressed over an element.  
onmousemove  
The onmousemove event occurs when the pointing device is moved while it is over an element.  
onmouseout  
The onmouseout event occurs when the pointing device is moved away from an element.  
onmouseover  
The onmousemove event occurs when the pointing device is moved while it is over an element.  
onmouseup  
The onmouseup event occurs when the pointing device button is released over an element.  
src  
Specifies the location of the image to be used in the control.  
style  
Specifies style information for the current element. The syntax of the value of the style attribute is determined by the default style sheet language.  
title  
Specifies advisory information about the element for which it is set.  
usemap  
Associates an image map with an element. The image map is defined by a MAP element. The value of usemap must match the value of the name attribute of the associated MAP element.  
vspace  
Specifies the amount of white space to be inserted above and below an image.  
width  
Specifies the image and object width override.  
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!