Session 01 - The Internet, World Wide Web, Web Browsers

Harvard University Extension School
Fall 2017

Course Web Site: http://cscie12.dce.harvard.edu/

Instructor email: david_heitmeyer@harvard.edu
Course staff email: cscie12@dce.harvard.edu

Topics

  1. The Internet and the World Wide Web
  2. A Web Site over Time
  3. Components of the Web
  4. Client-side Web Parts: Markup, Style, Function
  5. HTML Introduction
  6. Markup Evolution and Standards
  7. HTML/SGML/XML -- What's the Difference?
  8. HTML5

slide1 slide2 slide3 slide4 slide5 slide6 slide7 slide8 slide9 slide10 slide11 slide12 slide13 slide14 slide15 slide16 slide17 slide18 slide19 slide20 slide21 slide22 slide23 slide24 slide25 slide26 slide27 slide28 

The Internet and the World Wide Web

The Internet

key

Image from Opte Project and is used under the Creative Commons Attribution-NonCommercial 4.0 International License.

The Internet: Schematic

Internet

Types of Traffic on the Internet

Internet

The World Wide Web

Web 25th Anniversary (2014)
The Web at 25

Tim Berners-Lee on The World Wide Web

Web at 25

Today, and throughout this year, we should celebrate the Web’s first 25 years. But though the mood is upbeat, we also know we are not done. We have much to do for the Web to reach its full potential. We must continue to defend its core principles and tackle some key challenges.

Tim Berners-Lee in Welcome to the Web's 25 Anniversary
Long Live the Web

The Web evolved into a powerful, ubiquitous tool because it was built on egalitarian principles and because thousands of individuals, universities and companies have worked, both independently and together as part of the World Wide Web Consortium, to expand its capabilities based on those principles.

Tim Berners-Lee in Long Live the Web (Scientific American, Nov/Dec 2010)
Weaving the Web

The irony is that in all its various guises -- commerce, research, and surfing -- the Web is already so much a part of our lives that familiarity has clouded our perception of the Web itself.

Tim Berners-Lee in Weaving the Web (1999)

Features of the World Wide Web

Approaching the Web

Understand Reality

Approach Based on Reality

A Web Site over Time

The White House Site (www.whitehouse.gov)

1996
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1996

1997
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1997


1997
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1997

1998
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1998


1998
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1998

1999
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1999


1999
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1999

2001
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2001


2001
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2001

2002
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2002


2002
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2002

2007
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2007


2007
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 1996

2009
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2009


2009
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2009

2011
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2011


2011
whitehouse.gov
Internet Archive Way Back Machine - whitehouse.gov 2011

2015 - Early
whitehouse.gov


2015 - Early
whitehouse.gov

2015 - Late
whitehouse.gov

2017 - January. A new administration.
whitehouse.gov

2017 - August
whitehouse.gov

A Web Address - URLs and URIs

Names and Locations: URLs, URIs, and URNs

URI, URN, URL

Components of the Web

web parts

1. HTTP Client

http clienthttp client

2. HTTP Server

server-sideserver

3. Network

Network connecting HTTP client with server.

Client-side Web Parts: Markup, Style, Function

web parts

Our Solar System: Markup

solarsystem-markup.html
markup

Our Solar System: Markup + Style

solarsystem-style.html
markup + style

Our Solar System: Markup + Style + Function

solarsystem.html
markup + style + function

Files:

HTML Introduction

HTML5

Markup - HTML

The Code

<!DOCTYPE html>
<html>
  <head>
    <title>My Schools</title>
  </head>
  <body>
    <h1>My Schools</h1>
    <ul>
      <li>
        <a href="http://www.harvard.edu/">Harvard University</a><br/>
        <img src="images/veritas.gif" alt="Harvard Shield" />
      </li>
      <li>
        <a href="http://www.ku.edu/">University of Kansas</a><br/>
        <img src="images/KUSeal.gif" alt="University of Kansas Seal" />
      </li>
    </ul>
  </body>
</html>

How a Browser Displays It

web page

How Your Browser Thinks About It

dom tree

Essential HTML5 Document Structure

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8" />
    <title>Document Title</title>
  </head>
  <body>
    <!-- content goes here -->
  </body>
</html>

Components of HTML Elements

A Hypertext Link

Markup for a Hypertext link:

<a href="http://www.harvard.edu/">Harvard</a>

How it would render in a web browser:
Harvard Link in a web browser


element anatomy


Start Tag
<a href="http://www.harvard.edu/">Harvard</a>

Element Name
<a href="http://www.harvard.edu/">Harvard</a>

Attribute
<a href="http://www.harvard.edu/">Harvard</a>

Attribute Value
<a href="http://www.harvard.edu/">Harvard</a>

Content
<a href="http://www.harvard.edu/">Harvard</a>

End Tag
<a href="http://www.harvard.edu/">Harvard</a>

Markup Evolution and Standards

markup evolution

Markup Standards

Benefits of Web Standards

Standards for:
Benefits:
"Be liberal in what you accept, and
conservative in what you send"

"Postel's Law" or the "Robustness Principle"

HTML/SGML/XML -- What's the Difference?

Main differences between HTML/SGML and XML:

 HTMLXML
1.End tags can be "implied"
Closing elements that have implied end tags

<img src="images/lake.jpg" alt="Lake" >

<ul><li>coffee<li>tea</ul>

End tags always required
(even for "empty" elements)

<img src="images/lake.jpg" alt="Lake" />

<ul><li>coffee</li><li>tea</li></ul>

2.Start tags can be "implied"
<!DOCTYPE html>
<head>
<title>My Document</title>
<body>
<h1>My Document</h1>
Start tags always required
<!DOCTYPE html>
<html>
<head>
<title>My Document</title>
</head>
<body>
<h1>My Document</h1>
</body>
</html>
3.Element and attribute names are not case-sensitive

<IMG SrC="images/lake.jpg" aLT="Lake" >

Element and attribute names are case-sensitive

<img src="images/lake.jpg" alt="Lake" />

4.Attribute values do not need to be in quotes if the values contain alpha-numeric characters only

<img src=images/lake.jpg alt=Lake >

Attribute values must always be in quotes
 

<img src="images/lake.jpg" alt="Lake" />

Best Practices for Starting Out

A Tale of Two Documents

XML Syntax

<!DOCTYPE html>
<html>

<head>
    <title>My Document</title>
</head>

<body>
    <h1>My Document</h1>
    <ul>
        <li>coffee</li>
        <li>tea</li>
    </ul>
    <img src="images/lake.jpg" alt="Lake" />
</body>

</html>

SGML/HTML Syntax

<!DOCTYPE html>

<HEAD>
    <TITLE>My Document</TITLE>
<BODY>
    <H1>My Document</H1>
    <UL>
        <LI>coffee
        <LI>tea
    </UL>
    <IMG SRC=images/lake.jpg ALT="Lake" >
Markup - XML syntax
Validate with Nu Html Checker
Markup - SGML/HTML syntax
Validate with Nu Html Checker

HTML5

117 elements defined in HTML5 HTML5 Logo

More information: HTML5 Living Standard from the WHATWG. Section 4 contains the List of elements in HTML.

Most commonly used elements

HTML5 Logo Start with these 17 — these are elements are found in an overwhelming majority of web pages!

Frequency of Occurence of Elements in Webpage

 

Distinct Elements In a Webpage

 

Elements that Make up a Page - and How Many Times

Data on Pages goes here...
thumbthumbthumbthumbthumb

Copyright © David Heitmeyer