How to work with images in HTML

In this article we will discuss about the image tag used in HTML.
  • 2196

Images in HTML

It is possible to add images in the HTML document and for this <img> tag is used. In this tag we have an attributes called src in which we give the path of the image which will be displayed in the HTML document. We can also change the width and height of the images. For this we have to use width and height attributes.

HTML code:

    <img src="Desert.jpg" height="30%" width="30%"></img><br />
        <img src="Koala.jpg" height="30%" width="30%"></img></center>



Here <center> tag is also has been applied on the image which displays the image in the center of the HTML document. We can set the height and width according to our application requirement.

Ask Your Question 
Got a programming related question? You may want to post your question here


More Articles

© 2020 DotNetHeaven. All rights reserved.