| < Day Day Up > |
|
The <html:img /> tag is used to render an HTML <img> element. The image URL generated for this image is calculated using the value identified by the src or page attributes. You must specify one of the src or page attributes. The <html:img /> has no body and supports 40 attributes, described in Table 16.11.
Attribute | Description |
---|---|
align | Defines the image alignment of this image. (optional) |
alt | Defines an alternate text string for this element. (optional) |
altKey | Defines a resources key (to be retrieved from a resource bundle) that references an alternate text string for this element. (optional) |
border | Defines the width, in pixels, of the image border. (optional) |
bundle | Specifies a MessageResources key of the resource bundle defined in the struts-config <message-resource> element. The default key is ApplicationResources. (optional) |
height | Indicates the height of the image, in pixels. (optional) |
hspave | Specifies the amount of horizontal space, in pixels, between the image and the text. (optional) |
imageName | Defines a JavaScript name that can be referenced by JavaScript methods. (optional) |
ismap | Specifies a server-side map that this image references, if applicable. (optional) |
locale | Specifies the session attribute containing the Locale instance of the current request. This Locale is then used to select Locale-specific text messages. (optional) |
lowsrc | Specifies an image for clients with low-resolution graphics cards. (optional) |
name | Identifies a scripting variable containing a java.util.Map object of parameters and values to be appended to the src attribute, enabling the dynamic augmentation of the image src. (optional) |
onclick | Specifies a JavaScript function that is executed when this element receives a mouse click. (optional) |
ondblclick | Specifies a JavaScript function that is executed when this element receives a mouse double-click. (optional) |
onkeydown | Specifies a JavaScript function that is executed when this element has focus and a key is pressed. (optional) |
onkeypress | Specifies a JavaScript function that is executed when this element has focus and a key is pressed and released. (optional) |
onkeyup | Specifies a JavaScript function that is executed when this element has focus and a key is released. (optional) |
onmousedown | Specifies a JavaScript function that is executed when this element is under the mouse pointer and a mouse button is pressed. (optional) |
onmousemove | Specifies a JavaScript function that is executed when this element is under the mouse pointer and the pointer is moved. (optional) |
onmouseout | Specifies a JavaScript function that is executed when this element is under the mouse pointer but the pointer is then moved outside the element. (optional) |
onmouseover | Specifies a JavaScript function that is executed when this element is not under the mouse pointer but the pointer is then moved inside the element. (optional) |
onmouseup | Specifies a JavaScript function that is executed when this element is under the mouse pointer and a mouse button is released. (optional) |
paramId | Specifies a request parameter that is added to the generated src URL when the hosting JSP is requested. (optional) |
page | Specifies the application-relative path of the image source used by this input tag. (optional) |
pageKey | Specifies a resources key (to be retrieved from a resource bundle) that references an application-relative path of the image source used by this input tag. (optional) |
paramName | Identifies the name of a scripting variable of type java.lang.String that references the value for the request parameter identified by paramId attribute. (optional) |
paramProperty | Identifies a data member of the bean named by the paramName attribute that is dynamically added to this src URL. (optional) |
paramScope | Identifies the scope of the bean specified by the paramName attribute. If the paramScope attribute is not specified, then the tag will search for the bean in the scopes, in the order of page, request, session, and application. (optional) |
property | Identifies a data member of the bean named by the name attribute that contains the java.util.Map object of parameters. (optional) |
scope | Identifies the scope of the bean specified by the name attribute. If the scope attribute is not specified, then the tag will search for the bean in the scopes, in the order of page, request, session, and application. (optional) |
src | Specifies a URL that references the location of the image source used by this tag. (optional) |
srcKey | Specifies a resources key (to be retrieved from a resource bundle) that references a URL pointing to the location of the image source used by this tag. (optional) |
style | Specifies a Cascading Style Sheet style to apply to this tag's HTML element. (optional) |
styleClass | Specifies a Cascading Style Sheet class to apply to this tag's HTML element. (optional) |
styleId | Specifies an HTML identifier to be associated with this tag's HTML element. (optional) |
title | Specifies the advisory title for this HTML element. (required) |
titleKey | Specifies a resources key (to be retrieved from a resource bundle) that references a title string for this element. (optional) |
usemap | Specifies a coordinate map used when hyperlinking a hotspot of this image. (optional) |
vspace | Indicates the amount of vertical spacing between the identified image and its surrounding text. (optional) |
width | Indicates the width of the image being displayed. (optional) |
| < Day Day Up > |
|