Javascript
Upcoming SlideShare
Loading in...5
×
 
  • 4,116 views

 

Statistics

Views

Total Views
4,116
Views on SlideShare
2,909
Embed Views
1,207

Actions

Likes
1
Downloads
58
Comments
0

3 Embeds 1,207

https://pic.fsu.edu 945
http://pic.fsu.edu 260
http://192.168.102.42 2

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Javascript Javascript Presentation Transcript

  •  
  • Programming Languages
    • All have…
      • Variables, data types, assignment
      • Arithmetic, relational, and logical operators, and expressions
      • Control structure: if-then, while, loops, iteration
      • Program structure: functions, objects, methods
      • Arrays and strings
      • Input and Output
  • What is JavaScript?
    • JavaScript is a programming/scripting language designed for the Web
    • Javascript is interpreted not compiled
    • JavaScript is not Java
    • JavaScript provides interactivity for Web pages
    • JavaScript may be embedded in HTML or referenced from HTML (like CSS)
    • JavaScript is forgiving and easy to use
    View slide
  • JavaScript is Object-Oriented
    • JavaScript uses objects that have attributes and methods
    bgColor is an attribute of the document object document.bgColor=“#888888”; write is a method in the document object document.write(“Hello Earl!”); The DOM (Document Object Model) View slide
  • JavaScript is typically used to enhance a Web interface http://pic.fsu.edu/courses/wdp/current/tutorials/javascript/examples/mouseover2.html http://pic.fsu.edu/courses/wdp/current/tutorials/javascript/coolmenu/ http://javascript.internet.com/toc.html http://sixrevisions.com/rapid-development/10_ajax_effects_website_fanciness/ Javascript is a key element in the popular AJAX programming methodology. Javascript code can reference Javascript libraries such as jQuery .
  • JavaScript Embedded in HTML
    • In the html <body>
  • JavaScript Embedded in HTML
    • In the html <body>
    http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/doc_write.html
  • JavaScript Embedded in HTML
    • In the html <head>
    http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/function.html
  • Working with Variables http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/variables.html
  • Working with Variables http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/variables2.html
  • HTML Forms
    • Javascript can collect user input through HTML forms.
    http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/form_objects.html http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/change_background.html http://www.w3schools.com/html/html_forms.asp
  • Calling a function from a form http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/form_adder.html http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/form_adder2.html v1 and v2 are two variables being passed into function add this.form.v1.value gets the value the user typed in the v1 textbox on the form in this document The button calls the function add when it is clicked (onclick)
  • if – elseif - else http://www.pic.fsu.edu/courses/wad/tutorials/javascript/examples/if_else.html