URLs
URL is an acronym for Uniform Resource Locator. Every resource on the web
(every HTML document, image, sound, etc.) has a unique address given by its URL.
Every URL has several parts:
- the protocol required to access the resource
- the domain name of the host which has the resource
- the name of the file that contains the resource and the path
to that file on the host computer (this part of the URL is not
required for some URLs)
Some of the more commonly used protocols include:
- http
- The hypertext transfer protocol is used for transferring web pages
between the server and the browser.
- ftp
- The file transfer protocol is used for copying files between
computers on the Internet.
- mailto
- The mailto scheme is used to open a mail window to allow the user to
easily send an email to a specific email address.
- file
- The file scheme is used to access a file on a local disk.
Examples
- http://www.nytimes.com/aponline/world/AP-Iran-Nuclear.html
- This is the URL for a web page, therefore, the protocol is http. The
next part of the URL is the domain name of the host that contains the web page
(www.nytimes.com). The last part of the URL is
the path to the file (/aponline/world), and the name of the file
that contains the
web page (AP-Iran-Nuclear.html).
- http://www.middlesexcc.edu
- This is the URL for a web page, therefore, the protocol is http. The
next part of the URL is the domain name of the host that contains the web page
(www.middlesexcc.edu) In this case, a default file will be sent back
by the server; usually this default file is named index.html
or index.htm.
- ftp://www.math.rutgers.edu/pub/ostheime/thesis.ps.gz
- This is a URL for a file that can be downloaded from the machine
www.math.rutgers.edu.
The name of the file is thesis.ps.gz, and the path to the file is
/pub/ostheime.
- mailto:benweber@benweber.com
- This URL brings up an email window with the To: field containing
benweber@benweber.com
- file:///c|/My%20Documents/mcc/web/index.html
- This URL refers to a file on the local C: drive. Notice that there are
three slashes in
this URL after the protocol name. Also, notice that the drive is indicated
by C| rather than
C:. Also, there cannot be a blank within a URL, so if there is a space in
the file name,
it must be indicated by its ASCII code preceded by a %. Since 20
(hex) is the
ASCII code for space, the space in the URL is indicated by %20.
- myspace.com
- There is no protocol in this URL. In a web browser, the protocol defaults
to http, so this URL will access the default web page at the host
myspace.com.
Email Me |
Office Hours |
My Home Page |
Department
Home |
MCC Home Page
© Copyright Emmi Schatz 2007