CS 101   Web Construction,  Winter 2012,  Instructor:  Jeffrey Horn   GUIDE TO THE FINAL EXAM


TIME AND LOCATION

GENERAL

TOPICS  (not necessarily complete, but I tried!)

  1. BASIC HTML
  2. MORE HTML
    1. Inserting local and remote images.
    2. Hyperlinks to local and remote web pages.
    3. Making images become  hyperlinks.
  3. BASIC CSS
  4. FORMS
    1. What the action attribute specifies.
    2. How the submit button triggers the action.
    3. How to NAME datafields in the form so that their values are sent when the submit button is clicked.
    4. How the serverside script generates an html web page dynamically, and sends it back to the browser.
    5. How the server can do other things with the data that it is sent (e.g., email, update a database)
  5. BASIC JAVASCRIPT
    1. How to add javascript to a web page via the "onclick" attribute of a button, image, image map, etc.  When will this code run?  This code will only run when the user actually clicks on the html element that has this javascript as its "onclick" attribute!
    2. How to add javascript to a web page via the "<script>" element (in the <head>).  When will this code run?  This code will only be run once, when the page is first loaded.
    3. Javascript syntax (semi-colons at the end of each statement, case-sensitivity, comment syntax which is "//" and "/*").
  6. OTHER TOPICS:
    1. Accessibility:  use of "alt" attribute for images, to describe image in words.
    2. Know how to use the browser's "view source" to get at web page's source code".
    3. Server-side vs. client-side scripts (what are the differences?)
    4. Server operation:  e.g., what gets served up out of the pub folder (answer:  everything!)

HTML ELEMENTS you should know (not necessarily complete!)

Document Structure:  <html><head><title><body><!--  comment -->

Text Spacing and Formatting:  <i><b><sub><sup><big><small><strong><cite><hr /><br /><quote>

Text Headings:  <h1><h2><h3><h4><h5><h6>

Grouping Text:  <p><dif> <span>

Lists:  <ul><ol><li>

Tables:   <table><tr><td><th><caption>

Forms and Programming:  <form><input type="text"><input type="radio"><input type="checkbox"><input type="submit"><textarea><select><script><input type="hidden"> <input type="button"> <input type="password"><input type="reset">

Others:   <img><a><style>

CSS PROPERTIES you should be aware of (not necessarily complete!)

You should feel comfortable with the css on this handout (you can skip the material on the bottom 12 lines).   By that I do not mean that you are expected to memorize these properties; just be able to have some idea what each does, if you come across them in some code, and be able to look them up if you need to use them yourself, ever.  On the final exam, I might give you the URL of some external css file, like the one for this handout, and ask you what that stylesheet does to your level 2 header (that is, <h2> element).   To answer such a question you might read the css file or you could link to it in an html file and view it in a browser.

JAVASCRIPT COMMANDS you should know (not necessarily complete!)

Javascript Command Example
alert alert("Your age is below the minimum!");
if-then-else

if( age <  0)  
   alert("You are too young to enter.");
   else alert("You may enter");  

var var x;
assignment x = 1;
incrementing a variable x=x+1;     or    x++;
assignment to part of a form document.forms.myForm.totalPayment.value = cost_of_items + shipping + tax;  // Thji is code using the Document Object Model (DOM)
document.getElementById("totalPayment").value = cost_of_items + shipping + tax;
changing any attribute in a web page document.images.aardvark.width = document.images.aardvark.width + 10; // Thji is code using the Document Object Model (DOM)
document.getElementById("aardvark").width =                  //  This assumes that the <img> element has id="aardvark".
                                                            document.getElementById("aardvark").width  + 10;
document.images.barnyardAnimal.src = "horse.gif";

document.getElementById("barnyardAnimal").src = "horse.gif";   //  This assumes that the <img> element has id="barnyardAnimal".
comment
//    Use double slashes for short, one line comments

/*  This is the syntax for comments that span more than one line.  You can use whole paragraphs for comments, just by putting the slash-star and star-slash delimiters around the whole thing!  */

CS 101 Fall 2008 Final Exam Guide