032.3 HTML References and Embedded Resources Flashcards
Any modern web page is rarely made of just text.
It comprises many other types of contents, such
as images, audio, video and even other HTML documents.
The most common type of embedded content
Images are kept
separately and are referenced inside the HTML file with the <img></img> tag:
<img></img>
The <img></img> tag does not require
a closing tag
indicates the source location for the image file.
src property
<img></img>
<img></img>
The two dots indicate that the image
is located inside the parent directory relative to the directory where the HTML file is
applies if the HTML file isn’t an actual file in the filesystem; the HTML browser interprets the URL as if it is a path to a file, but it is the HTTP server’s job to decide whether that path refers to a file or to dynamically generated content.
dot notation
absolute paths.
Source locations beginning with a forward slash /
composed of geographically distributed servers that
store static content for other websites. They help to improve performance and
availability for heavy accessed sites
Content Delivery Networks
attribute is also important for accessibility. Text-only browsers and screen readers use it as a description for the corresponding image.
alt
distorted when the original size is smaller than the new dimensions or when the
new proportion ratio differs from the original
images
Doing this to large images uses extra bandwidth that will result in longer loading timings.
downsizing