Once a browser gets the main html page, how does it know which are the embedded content should be request again from web server, and which are only external links? Is it based on type of tags, e.g ?
If so, could someone give me a reference of what these tags are?
Thanks.
Yes, the tags help browser identify the resources to load. After downloading/retrieving the content the browser determines what to do with the content based on the content-type header in the response.
The HTML5 spec defines the element category "Embedded content":
It lists the following elements:
audio
canvas
embed
iframe
img
math
object
svg
video
Elements like
link
orscript
(both in Metadata category) can also refer to other ressources that user-agents (browsers, screen-readers, …) are free to link to or include or do whatever they want to do with it. For example, browsers like Firefox or Chromium will (by default) load and "apply" CSS that is linked within thelink
element, that has therel
value =stylesheet
. Browsers like Lynx or w3m won't do that. They simply ignore that link.For
link
, HTML5 states which link types "are links to resources that are to be used to augment the current document, generally automatically processed by the user agent":Maybe also consider the
style
attribute (for inline CSS), which could include abackground-image
url
.