Web Designs & Languages
Web Designs & Languages
CSC1720 – Introduction to Internet
CSC1720 – Introduction to Internet
Essential Materials
Essential Materials
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
2
Outline
Outline
WWW and Internet
WWW and Internet
Web Server and Web Clients
Web Server and Web Clients
How does the WWW work?
How does the WWW work?
Who defines the Web standards?
Who defines the Web standards?
Web Programming Languages
Web Programming Languages
–
Markup Languages
Markup Languages
HTML, WML, XML, XHTML
HTML, WML, XML, XHTML
–
Client-side & Server-side Scripting
Client-side & Server-side Scripting
JavaScript, VBScript, Java Servlets, ASP, JSP
JavaScript, VBScript, Java Servlets, ASP, JSP
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
3
The World Wide Web
The World Wide Web
Affectionately called “
Affectionately called “
The Web
The Web
”
”
It is a collection of information stored on the
It is a collection of information stored on the
networked computers over the world.
networked computers over the world.
The WWW was proposed in 1991 by Tim Berners-Lee
The WWW was proposed in 1991 by Tim Berners-Lee
at CERN.
at CERN.
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
4
Web or Internet?
Web or Internet?
They are not the same things.
They are not the same things.
The Internet is a collection of computers or
The Internet is a collection of computers or
networking devices connected together.
networking devices connected together.
–
They have communication between each other.
They have communication between each other.
–
Decentralized design that there is no centralized
Decentralized design that there is no centralized
body controls how the Internet functions.
body controls how the Internet functions.
The Web is a collection of documents that are
The Web is a collection of documents that are
interconnected by hyper-links.
interconnected by hyper-links.
–
These documents are accessed by web browsers
These documents are accessed by web browsers
and provided by web servers.
and provided by web servers.
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
5
Internet Terminology
Internet Terminology
Client
Client
–
Any computer on the network that requests
Any computer on the network that requests
services from another computer on the network.
services from another computer on the network.
Server
Server
–
Any computer that receives requests from client
Any computer that receives requests from client
computers, processes and sends the output.
computers, processes and sends the output.
Web Page
Web Page
–
Any page that is hosted on the Internet.
Any page that is hosted on the Internet.
Web Development
Web Development
–
The process of creating, modifying web pages.
The process of creating, modifying web pages.
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
6
Web Browser (Web Client)
Web Browser (Web Client)
It is a program that retrieves information from the
It is a program that retrieves information from the
Web.
Web.
–
Microsoft Internet Explorer
Microsoft Internet Explorer
Most commonly used browsers
Most commonly used browsers
–
Netscape, Mosaic
Netscape, Mosaic
Many different computing platforms
Many different computing platforms
–
Opera
Opera
The fastest browser on Earth
The fastest browser on Earth
–
Lynx
Lynx
Text based web client
Text based web client
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
7
Lynx – UNIX based
Lynx – UNIX based
Text
Text
mode
mode
browser,
browser,
fast!
fast!
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
8
Some Statistics
Some Statistics
Until July 02
Until July 02
–
Internet Explorer 6.x
Internet Explorer 6.x
39%
39%
–
Internet Explorer 5.x
Internet Explorer 5.x
51%
51%
–
Internet Explorer 4.x
Internet Explorer 4.x
2%
2%
–
Netscape
Netscape
3%
3%
–
Others
Others
1%
1%
–
Win98/ME
Win98/ME
64%
64%
, Win 95
, Win 95
4%
4%
–
WinNT
WinNT
5%
5%
, Win2000
, Win2000
20%
20%
–
MAC
MAC
1%
1%
, www.thecounter.com
, www.thecounter.com
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
9
Internet Explorer
Internet Explorer
Version 1.0
Version 1.0
- August 1995
- August 1995
Version 2.0
Version 2.0
- November 1995
- November 1995
Version 3.0
Version 3.0
- August 1996
- August 1996
Version 4.0
Version 4.0
- October 1997
- October 1997
–
Support CSS & DOM, but no XML
Support CSS & DOM, but no XML
Version 5.0
Version 5.0
- March 1999
- March 1999
Version 5.5
Version 5.5
- July 2000
- July 2000
Version 6.0
Version 6.0
- August 2001
- August 2001
–
The latest version
The latest version
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
10
Netscape Navigator
Netscape Navigator
Netscape 1.0
Netscape 1.0
- December 1994
- December 1994
Netscape 2.0
Netscape 2.0
- March 1996
- March 1996
Netscape 3.0
Netscape 3.0
- August 1996
- August 1996
Netscape 4.0
Netscape 4.0
–
The latest one is 4.79
The latest one is 4.79
Mozilla
Mozilla
Netscape 5.0
Netscape 5.0
- Skipped
- Skipped
Netscape 6.0
Netscape 6.0
- November 2000
- November 2000
Netscape 6.1
Netscape 6.1
- August 2001
- August 2001
Netscape 6.2
Netscape 6.2
- November 2001
- November 2001
Netscape 7.0
Netscape 7.0
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
11
Web Server
Web Server
It is a program that waits for requests from
It is a program that waits for requests from
the web browser.
the web browser.
It provides four major functions
It provides four major functions
–
Serving web pages
Serving web pages
–
Running gateway programs (CGI) and returning
Running gateway programs (CGI) and returning
output
output
–
Controlling access to the server
Controlling access to the server
–
Monitoring and logging all access
Monitoring and logging all access
E.g. Apache, IIS, Netscape Web server, …
E.g. Apache, IIS, Netscape Web server, …
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
12
Web connection
Web connection
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
13
Web Server - Example
Web Server - Example
The URL Where you place your web site
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
14
Web Server Statistics
Web Server Statistics
Apache vs. MS
6 : 3
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
15
Which server is running?
Which server is running?
Examine
Examine
www.cuhk.edu.hk
www.cuhk.edu.hk
from
from
netcraft
netcraft
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
16
How does the Web work?
How does the Web work?
The web information is stored in the Web pages.
The web information is stored in the Web pages.
–
In HTML format.
In HTML format.
The web pages are stored in the computers called
The web pages are stored in the computers called
Web servers.
Web servers.
–
In the Web server file system.
In the Web server file system.
The computer reading the pages is called web clients
The computer reading the pages is called web clients
with specific web browser.
with specific web browser.
–
Most commonly Internet Explorer or Netscape.
Most commonly Internet Explorer or Netscape.
The web server waits for the request from the web
The web server waits for the request from the web
clients over the Internet.
clients over the Internet.
–
Internet Information Server (IIS) or Apache.
Internet Information Server (IIS) or Apache.
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
17
The HTTP
The HTTP
Request/Response Model
Request/Response Model
Client Server
Request
Response
HTML Codes
<html>
…
</html>
Program /
Scripts
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
18
Valid HTTP
Valid HTTP
Request/Response mesgs
Request/Response mesgs
Provides additional information
Provides additional information
GET /index.html HTTP/1.0
Host: www.anyhost.com
User-Agent : Mozilla/4.5 [en] (WinNT; I)
Accept : image/gif, image/jpeg, */*
Accept-language : en
Accept-charset : iso-8859-1, *, utf-8
HTTP/1.0 200 OK
Last-Modified: Mon, 20 Dec 1999 …
Date: Tue, 11 Jan 2002 …
Status: 200
Content-Type: text/html
Servlet-Engine: Tomcat Web Server
Content-Length: 59
<html>
…
</html>
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
19
HTTP
HTTP
HTTP (
HTTP (
H
H
yper
yper
t
t
ext
ext
T
T
ransfer
ransfer
P
P
rotocol)
rotocol)
–
protocol used to access data on the WWW.
protocol used to access data on the WWW.
–
uses one TCP connection on well-known port 80.
uses one TCP connection on well-known port 80.
–
two types of http messages:
two types of http messages:
Request
Request
,
,
Response
Response
–
transfer data in the form of plain text, hypertext,
transfer data in the form of plain text, hypertext,
audio, video, and so on.
audio, video, and so on.
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
20
HTTP
HTTP
DEMO!
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
21
Example –
Example –
Request/Response
Request/Response
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
22
Top-Level Domains
Top-Level Domains
Country code
domain
Generic
domain
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
23
IP Address Space
IP Address Space
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
24
Who defines the Web
Who defines the Web
standards?
standards?
The Web standards are not defined or setup by the
The Web standards are not defined or setup by the
browser companies or Microsoft, but the World Wide
browser companies or Microsoft, but the World Wide
Web Consortium (
Web Consortium (
W3C
W3C
).
).
The specifications form the Web standards.
The specifications form the Web standards.
–
HTML, CSS, XML, XHTML, …
HTML, CSS, XML, XHTML, …
CSC1720 –
Introduction to
Internet
All copyrights reserved by
C.C. Cheung 2003.
25
W3C
W3C
Quoted from
Quoted from
W3C
W3C
–
W3C's long term goals for the Web are:
W3C's long term goals for the Web are:
1.
1.
Universal Access
Universal Access
:
:
To make the Web accessible to all by
To make the Web accessible to all by
promoting technologies that take into account the vast
promoting technologies that take into account the vast
differences in culture, languages, education, ability, material
differences in culture, languages, education, ability, material
resources, and physical limitations of users on all continents;
resources, and physical limitations of users on all continents;
2.
2.
Semantic Web
Semantic Web
:
:
To develop a software environment that
To develop a software environment that
permits each user to make the best use of the resources
permits each user to make the best use of the resources
available on the Web;
available on the Web;
3.
3.
Web of Trust
Web of Trust
:
:
To guide the Web's development with careful
To guide the Web's development with careful
consideration for the novel legal, commercial, and social
consideration for the novel legal, commercial, and social
issues raised by this technology.
issues raised by this technology.