April 28, 2009

0 HTML Images

With HTML you can display images in a document.

The Image Tag and the Src Attribute

In HTML, images are defined with the <img> tag.

The <img> tag is empty, which means that it contains attributes only and it has no closing tag.

To display an image on a page, you need to use the src attribute. Src stands for "source".The value of the src attribute is the URL of the image you want to display on your page.

The syntax of defining an image.
-----------------------------------------------------------------------------------------
<img src ="url">
-----------------------------------------------------------------------------------------

The URL points to the location where the image is stored.An image named "boat.gif" located in the directory "images" on "www.mysite.com" has the URL: http://www.mysite.com/images/boat.gif.

The browser puts the image where the image tag occurs in the document.If you put an image tag between two paragraphs, the browser shows the first paragraoh, then the image and then the second paragraph.





0 comments:

Post a Comment

Blogger Themes

 
Powered by Blogger