Adding Images:
In HTML, there are various ways of storing images. Nevertheless, the main problem faced by the user while uploading images is time consumption. Images take more time to upload than text. However, the solution to this problem is to use image compressing formats. The two recommended image compressing formats are given below:


GIF:-
GIF has 256 colors and is able to manage the transparent areas of the picture. GIF picture format is considered as the best for banners, buttons and clipart. However, this format is not adequate for compressing photographs.


JPG:-
JPG has unlimited colors. Unlike GIF, it is unable to manage the transparent areas of the image. It is an excellent tool for compressing photographs and images but is poor in handling banners, buttons and clipart.


Note: If your image is saved in any other format then use a graphic program to convert the image into a JPG of GIF file.


Defining Images in HTML:

In HTML, we define images by using the <img> tag.


The Src Attribute:

The image tag only contains attributes. It does not have any closing tags.

The Source tag (src) is used to display the image on a page. The url of the image which you want to display is actually the value of the Source tag. It would be written as:

<img src=“url”>

The url which is to be placed in the inverted commas is the location of the image. The url could be something like:

http://visualbuilder.com/images/house.gif.


Where ever you place this tag, the browser will display the image there.


 


 

                    

Copyright © 2008 VisualBuilder. All rights reserved