HTML: Image tag

The <img> tag is used to insert images on web pages.

AttributeValueDescription
srcURLSpecifies the URL of an image
alttextSpecifies an alternate text for an image
widthpixelsSpecifies the width of an image
heightpixelsSpecifies the height of an image
ismapismapSpecifies an image as a server-side image-map
usemap#mapnameSpecifies an image as a client-side image-map

src attribute

<img src=“car.jpg”>
<img src=“C:\image\dog.jpg”>

alt attribute

<img src=“car.jpg” alt=“car”>

// If the image is not to be open then its attribute message show in alt=”car”.

Width and height attribute

<img src=“car.jpg” alt=“car” width=“200” height=“100”>

ismap attribute

click coordinates are sent to the server.

vikashdev k
Latest posts by vikashdev k (see all)
Tagged : / / / / / / / / /
0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x