CSC 551: Web Programming
Specific goals for the course
To develop an understanding of the technology and protocols underlying the Web.
To become familiar with the common tools and techniques for developing Web-based
applications, both client-side and server-side.
developing Web applications.
programming & problem solving
interface design and implementation
ability to research and learn from external sources
collaborative learning & development
Internet & Web technologies
history of Internet
networking 7-layer model, TCP/IP protocols
history of World Wide Web
HyperText Transfer Protocol (HTTP)
GET/POST requests, request headers (e.g., If-Modified-Since, ...)
response headers (e.g., status code, Last-modified, ...)
static vs. dynamic pages, client-side vs. server-side programming
HyperText Markup Language (HTML)
tags vs. elements
structural elements, text layout, text styles, lists
hyperlinks, images, tables, frames
STYLE attribute for an element vs. STYLE tag in HEAD vs. STYLE file
variables: loosley typed, don't have to declare
assignments, operators, control statements similar to C++
predefined functions (e.g., Math.sqrt)
user-defined functions: typeless, can declare local variables
predefined classes/objects: String, Array, Date, document, navigator
user-defined classes: awkward to define, no info hiding
code is embedded in SCRIPT tags, executed when page loads
output produced by document.write appears in page
code is specified in page elements, called to handle events
e.g., OnClick, OnMouseOver, OnMouseOut events for link/image
form elements: button, text box, text area, selection list, ...
properties: e.g., name, type value
methods: e.g., blur(), focus(), click()
event handlers: e.g., onblur, onfocus, onchange, onclick, ...
techniques: form validation, output to window/frame, timeouts, cookies
platform independence, portable, secure, simple, object-oriented, ...
source code compiled into Java byte code, then interpreted
basic syntax similar to C++, but simpler & more robust
class vs. instance variables/methods, primitive vs. reference types
no explicit pointers, automatic garbage collection
extensive library support: String, Array, Vector, Stack, HashTable, ...
no templates, but can store arbitrary Objects via inheritance, wrappers
inherit from Applet class, default methods include init, paint, ...
APPLET & OBJECT tags, applet parameters & dimensions
Graphics object, methods (drawRect, drawString, ...), double buffering
GUI elements, applet layout, event handling
JavaBeans: reusable, packaged components
Java Archive (JAR) files: multiple Java files/classes zipped together
extract window object, document object, form object, field object, ...
advantages: cross-platform, more tools/power, code integrity
Common Gateway Interface (CGI)
language-neutral protocol for Web server/program communication
reads from standard input: URL-encoded data containing field names & values
writes to standard output: response header + blank + page data
Microsoft DNA, including Active Server Pages
server-independent technologies: Java servlets
server-side equivalent to applets; similar to CGI but executed by server
advanced Web development tools: Cold Fusion vs. WebObjects
Dynamic HTML, ActiveX, XML