Monday, September 27, 2010

Images

HTML The Tag and the Src Attribute


In HTML, images are defined with the tag.
The tag is empty, which means that it contains attributes only, and 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.

some_text
 
HTML The Alt Attribute


The required alt attribute specifies an alternate text for an image, if the image cannot be displayed.
The value of the alt attribute is an author-defined text:
Big Boat
he alt attribute provides alternative information for an image if a user for some reason cannot view it (because of slow connection, an error in the src attribute, or if the user uses a screen reader

No comments: