URLs and such

Dr. Greg Bernstein

Updated March 18th, 2021

Web Resources

Learning Objectives

  • Understand the purpose of a URL
  • Know the different parts of a URL
  • Know the purpose of the parts of a URL

Readings

The following is very well written and well illustrated and forms the basis for these slides:

Identifying Resources on the Web.

URx?

  • URI: Uniform Resource Identifier — this is the most general term.

  • URL: Uniform Resource Locator — these are what we will work with.

  • URN: Uniform Resource Name — Won’t be dealing with these for now.

Example URLs

From MDN

https://developer.mozilla.org
https://developer.mozilla.org/en-US/docs/Learn/
https://developer.mozilla.org/en-US/search?q=URL
http://www.example.com:80/path/to/myfile.html?key1=value1&key2=value2#SomewhereInTheDocument

Parts of a URL

  • Protocol/Scheme
  • Authority/Domain
  • Path (/)
  • Query (?)
  • Fragment (#)

Protocol/Scheme

From MDN

protocol

Other protocols include: https, ftp, ssh,…

Authority

From MDN

domain

Port

From MDN

port

This is the destination TCP port

Path

From MDN

path

Why did MS have to use \?

Query/Parameters

From MDN

query

Fragment

From MDN

fragment
// reveal.js plugins