HTML Images | Syntax | Insert Image | Height/Weight | Image Location | Image as Link
For good looking website, images are most important.
In this tutorial, we are going to discuss how to insert images on the HTML page.
HTML Image Tag ( <img> ) is used to display image on the web page.
Using <img> tag, you can insert images into HTML pages.
And also you can use an attribute for images to looking images good. you can use jpg, png, and gif files also.
The HTML image tag is an empty tag. which means it contains only attributes and there is no closing tag.
Syntax Explained.
1. <img> is empty tag.
2. <src> is the attribute. it specifies the image path.
3. <alt> specifies an alternate text.
With the help of an HTML image tag, you can insert any images on your web page.
Let's see an example of HTML image.
And the Result is,
If a browser cannot find an image, it will display the value of the alt attribute:
Using the width and height attribute in HTML images you can set the height and width of the image as per your requirement.
In case your images are in different folders, you need to give the correct location/path of the folder to display the image on the web page.
Using Anchor tag in HTML, you can also use images as a link. if any user clicks on an image it jumps to another page. to do this use <img> tag inside the <a> tag.
And the Result is,
Subscribe for more videos on our Youtube channel. if you like our tutorial please Like and Subscribe to our Facebook and Youtube.
0 Comments
To Learn:
Tutorials in a simple Way.
Excel with downloadable samples.
HTML with sample website code.
PowerPoint presentations.
MS Word for offical use.