|

Introduction to JavaScript/ASP - The basic tools of an E-Commerce Web Site.
This course aims to provide the students with an overview of JavaScript and
ASP (VBScript). This provides them with the tools to produce highly interactive
web sites. JavaScript provides client-side interaction with the user. ASP
provides a connection between the user and any server-side objects (i.e.
databases, files, remote email etc.).
JavaScript allows the web page designer to interact with the user by
accessing and manipulating objects on the client HTML page. The JavaScript code
can be used to: -
* Validate the text contained in text-boxes (checking for correctly formatted
dates or credit card numbers or postcodes, for example). * Allow visual
interaction based on the location and state of the mouse, i.e. changing images
when the mouse cursor move over or is click on a menu option (provides feedback
to user). * Load different images based on some external variable (the time,
date or number of visits to the web site). * Create cookies on the client
machine to monitor visits, store user and password information or to store user
preferences. * Allow dynamically created HTML to be introduced into the web
page to display content that based on user interaction i.e. a dynamic quiz
(questions are produced randomly and the answers are checked on the fly etc.).
ASP (Server-side VBScript) allows the web page designer to pass information
to and from web pages. The data is generally stored in a database of some kind
(Microsoft Access and SQL Server). ASP web pages can be considered to be data
driven i.e. the content of the page is dependant on data held in a database.
ASP pages allow the web page designer to: - * Take data such as name,
address and financial information from the user and store it in a database for
later use. * Display data such as product lists (and availability) taken
from a live database with up-to-date pricing and stock levels. * Using the
above lists, the user can order items which will be sent the correct name and
address. The cost will be debited from the correct credit card. * Cookies
produced from ASP can store user IDs thus allowing following visits to be
personalised (if the user requires this) Combining JavaScript and ASP allows
the web page designer to create web sites that provide client-side interaction
(a pleasant "feel") with the data driven interaction that provides business to
take place.
The course will be broken down into three sections, JavaScript, ASP and a
combination of the two: -
This will be an introduction to JavaScript. Firstly, some simple examples to
show how JavaScript can be incorporated into a Web Page and then an overview of
the document object modal (DOM).
Week 1 In JavaScript, a Web Page is viewed as an object (a document) with
the items on the page a sub objects. The document object and the objects that
make up the page can be accessed in several different ways. An object has
properties and events i.e. a button has a value (the text on the button) this is
a property. The button also has events, onClick is the event triggered when the
user clicks on the button. We shall look at some of the more commonly used
objects and their properties and events during the first week.
Week 2 During this week, we will look at some of the basic JavaScript
language constructs: - the use of conditional operations such as loops and
conditional statements. We shall look at some of the built-in functions such as
the alert function.
Week 3 We will cover some of the more commonly used JavaScript such as
image swapping (used in menus and advertising), we shall also cover the
management of framed Web Pages i.e. accessing objects across multiple Web Pages
arranged in a Frameset. This should allow us to produce profession looking
Web Sites i.e. a menu at the top or side that allows control over the entire
site.
Week 4 This week, we will cover Dynamic HTML. This allows us to write HTML
and web content in JavaScript i.e. we can change the HTML content depending on
the users actions or some other external action.
Week 5 This week, we will introduce ASP into the course. To keep the
examples simple, JavaScript will be kept to a minimum. Active Server Pages
allow processing to be performed on the HTML before it is transmitted to the
user. They are HTML pages with VBScript embedded into them. The VBScript is
processed on the web server before the page is transmitted so the user receives
only dynamically produced HTML, the VBScript is replaced by its output.
Week 5 In the first week of ASP, we will produce some simple examples. An
example may produce a table of numbers (1 to 10) using a loop with the table
contents dynamically inserted into the page i.e. all the table tags plus the
data. ASP pages must be accessed via a web server that can process ASP
pages. ASP/VBScript usually runs on Microsoft's Internet Information Server or
(for a test environment) Microsoft's Personal Web Server (which can run of a
standard standalone PC).
Week 6 ASP pages are generally used to maintain sites that manage data,
this data is usually held in a Database Management System such as Microsoft's
SQL Server or (for testing purposes) Microsoft's Access. We will cover the
fundamentals of SQL (Structured Query Language) in an ASP environment. This
language is used to process data stored one of the above DBMSs. This can be
a little confusing so the examples will be as simple as possible i.e. You will
be using ASP (VBScript) to create SQL statements to retrieve data that will be
displayed embedded into HTML - Can be complicated.
Week 7 This week, we will use the skills learnt last week to produce a
working ASP site i.e. we will have pages that (using a menu) will add, display,
change and delete data held in a table.
Week 8 This week, we will be looking at some of the built-in functions
available in ASP/VBScript i.e. Date (Data) formatting, managing numbers,
managing cookies etc.
Week 9 & 10 We will produce a working web site using JavaScript and
ASP/VBScript. This will simulate a simple e-shop with a shopping basket, goods,
managed stock levels and a final invoice. JavaScript will be used to validate
data and manage the menu system
|