Easy Tutorial
❮ Tag Bdi Att Meter Value ❯

HTML <input> alt Attribute

HTML <input> Tag

Example

An HTML form with an image submit button:


Browser Support

All major browsers support the alt attribute.


Definition and Usage

The alt attribute provides alternative text for the user when the image cannot be viewed for some reasons (such as slow internet connection, errors in the src attribute, images being disabled in the browser, or the user using a screen reader).

Note: The alt attribute can only be used with <input type="image">.


Differences Between HTML 4.01 and HTML5

None.


Syntax

Attribute Values

Value Description
text Specifies the alternative text for the image.

❮ Tag Bdi Att Meter Value ❯