View
2.638
Download
0
Tags:
Embed Size (px)
DESCRIPTION
Citation preview
C G S 2 8 3 5 Interdisciplinary Web Development
C G S 2 8 3 5 Interdisciplinary Web Development
What we’ve learned so far…
C G S 2 8 3 5 Interdisciplinary Web Development
Inserting script in html
Using functionsInserting comment in script
Selection with “If, else if”
Variable declaration &assignment
Strings & values
Concatenating strings& variablesOutput to Web page
Using Forms
Sending form data to function
Using arithmetic &comparison operators
C G S 2 8 3 5 Interdisciplinary Web Development
Switch instead of “if”
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/switch.html
C G S 2 8 3 5 Interdisciplinary Web Development
Looping
• Doing something over and over• Two kinds:
– for– while
C G S 2 8 3 5 Interdisciplinary Web Development
Iteration with “while”
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/while.html
C G S 2 8 3 5 Interdisciplinary Web Development
Iteration with “for”
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/for.html
C G S 2 8 3 5 Interdisciplinary Web Development
Working with Arrays
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/array.html
C G S 2 8 3 5 Interdisciplinary Web Development
Arrays – An Easier Way
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/array1.html
C G S 2 8 3 5 Interdisciplinary Web Development
Arrays – Even Easier
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/array2.html
C G S 2 8 3 5 Interdisciplinary Web Development
Arrays – Form Example
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/array3.html
C G S 2 8 3 5 Interdisciplinary Web Development
Generating Random Numbers
http://pic.fsu.edu/courses/2011/spring/cgs2835/tutorials/javascript/examples/random.html
C G S 2 8 3 5 Interdisciplinary Web Development
jQuery
• A library of Javascript functions to do common things that require a lot of programming
• http://www.w3schools.com/jquery/jquery_examples.asp