Because image tags<img> identify an image and are not content markup tags, there are no closing tags. When using an image tag a source (src) must be identified. The source is the location the image can be found. It can be in a directory or even a URL address.
<img src=”home.gif” />
In order to be within Section 508 standards, a text equivalent must be provided for every non-text element. Therefore, alt tags are required for all images that convey information. Information in the alt tag should reflect what the image is conveying. For example, an image that indicates a use needs to click the image to submit a form, the alt tag must say “submit form” or similar.
<img src=”home.gif” alt=”Back to Home”>
Images can be resized by using attributes to the image tag. Keep in mind that resizing large images to be smaller can cause long load times, and resizing a small image to be larger can make the image blurry and pixilated. Sizes are calculated in pixels.
<img src=”home.gif” alt=”Back to Home” width=”200” height=”25”>
Images can be aligned on a page by using align attributes.
<img src=”home.gif” alt=”Back to Home” align=”right”>