VersionW3C//DTD HTML 3.2 Final//EN
ElementIMG
Purposeimage; photo, icon, glyph, or illustration
DescriptionThis element places an image in a document. The alt attribute is used to display a string of text when the image can not be displayed (e.g., in non-graphical browsers). Note that it is a good idea to fill in the alt attribute so that users with non-graphical browsers can gain information. For example, when the image conveys information not explained in the text or the image is used in an anchor.
Start tagRequired <IMG>
Attributes
NameTypeDefaultComment
align( top | middle | bottom | left | right )#IMPLIEDvertical or horizontal alignment
alt CDATA #IMPLIEDfor display in place of image
border NUMBER #IMPLIEDinteger representing length in pixels; suggested link border width in pixels
height NUMBER #IMPLIEDinteger representing length in pixels; suggested height in pixels
hspace NUMBER #IMPLIEDinteger representing length in pixels; suggested horizontal gutter in pixels
ismap( ismap )#IMPLIEDuse server image map
src CDATA #REQUIREDUniform Resource Locator; see RFC1808 and RFC1738; url of image to embed
usemap CDATA #IMPLIEDUniform Resource Locator; see RFC1808 and RFC1738; use client-side image map
vspace NUMBER #IMPLIEDinteger representing length in pixels; suggested vertical gutter in pixels
width NUMBER #IMPLIEDinteger representing length in pixels; suggested width in pixels
ContentEMPTY
End tagForbidden
Referenced in A ADDRESS APPLET B BIG BLOCKQUOTE BODY CAPTION CENTER CITE CODE DD DFN DIV DT EM FONT FORM H1 H2 H3 H4 H5 H6 I KBD LI P PRE SAMP SMALL STRIKE STRONG SUB SUP TD TH TT U VAR
Example
SourceAppearance
<IMG Src="http://www.december.com/html/images/icon.gif" alt="logo for the HTML Station" align="middle"> Visit us today!
<P>
<IMG Src="http://www.december.com/html/images/icon.gif" alt="logo for the HTML Station" align="bottom" width="100" height="200" border="5"> Meeting your hypertext needs since 1996.
<P>
<MAP Name="mymap">
<AREA Shape="rect" Coords="0,0,100,50" Href="http://www.december.com/html/">
</MAP>
<IMG Src="../../images/icon.gif" Usemap="#mymap" Width="100" Height="100" Ismap>
logo for the HTML Station Visit us today!

logo for the HTML Station Meeting your hypertext needs since 1996.

search Search · star Market
2023-06-19 · John December · Terms © johndecember.com