HTML - Image (Img tag)

> (World Wide) Web - (W3|WWW) > HyperText markup Language (HTML)

1 - About

An image.

Advertising

3 - Definition

3.1 - HTML element

The img element represents an image where:

  • src stands for “source” that have as value an url or a data scheme.

If the src value begins:

<base href="http://example.com">

Read more: https://html.com/attributes/img-src/#ixzz5J3gk4Sk1

3.2 - img role

See also the related ARIA img role. A container for a collection of elements that form an image. An img can contain captions and descriptive text, as well as multiple image files that when viewed together give the impression of a single image.

3.3 - alt attribute

The alt attribute is an Alternate text that is shown when the image cannot be displayed (page read by a screen reader)

4 - Security

The img element can be used in conjunction with some other features as a way to effect a port scan from the user's location on the Internet. This can expose local network topologies that the attacker would otherwise not be able to determine.

5 - Style

img, embed, object, video {
  max-width: 100%;
}

6 - DOM Accessor

The document property document.images returns an HTMLCollection of the img elements in the Document.

7 - Placeholder Image

Advertising

8 - Documentation / Reference

web/html/img.txt · Last modified: 2019/04/14 14:25 by gerardnico