14.7 Relative URI
If a URI does not start with a scheme name, then this is called a ‘relative URI’. A relative URI is always related to some base, i.e., to some absolute URI. This base can be the URI of the displayed document or even the URI of the previous document. If there is no such URI, an implicit URI of the application can be used.
A relative URI can contain. or
.
. characters; they are a reference to a working or parent directory respectively. A relative URI is parsed in several independent parts: a server name, a path including a file name, a request, and a fragment. Individual parts are separated by the following characters: #
(fragment), ?
(query string), and so on.
Let’s take the base (which is the absolute URI) and replace its parts by a relative URI from right to left. Hence, in the displayed http://www.company.com/path/file.htm page, the following hypertext references (relative URIs) can be found:
#paragraph1 that can be translated to the following absolute...