CS 185C/286 - Lecture 9

Cover page image

Cay S. Horstmann

Lecture 9 Quiz 1

No quiz today


  1. Modernize Android client for Android 4, including tablets: Keith, Vakati, Wu
  2. Improve device integration with Android and iPhone client: location, phone, schedule, contacts, etc.: Pham, Li X, Li Y
  3. HTML5 Cinequest client: Nguyen, Yi, Yulianto
  4. Hemepath counter app: Dang, Eibagi, Karnes
  5. Samsung S-Pen: Sainion, Sivaraman, Tang
  6. Port Cinequest app (films only, not schedule) to Windows phone: Anderson, Cheung, Lehrmann

Weekly Report

Today's Lecture/Lab

Introducing HTML 5

A Template HTML 5 Document with jQuery Mobile

<!DOCTYPE html>
    <title>Hello HTML 5</title> 
    <meta name="viewport" content="width=device-width, initial-scale=1"/> 
		<link rel="stylesheet" href="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.css" />			
		<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
		<script src="http://code.jquery.com/mobile/1.3.0/jquery.mobile-1.3.0.min.js"></script>

<div data-role="page">

    <div data-role="header">
        <h1>My First HTML App!</h1>

    <div data-role="content">    
        <p>This is an HTML 5 app.</p>        



Hello HTML 5 app.

General formal of a document

The Head of a Document

The Body of a Document

Where to Find Examples

Understanding Javascript

Basic Syntax

Ways to invoke Javascript



Functions in Javascript

Below is an example of the syntax for declaring a function in Javascript

function swap(i, j, a)
    var tmp=a[i]; /* explicitly defined variables 
                     have scope within the function
                     if I had declared the variable 
                     implicitly it would have global scope */
    a[i] = a[j]; a[j] = tmp;




Reading Before Next Class


jQuery Mobile