Introduction to JavaScript. Introduction What is it? How does it work? What is Java? Learning JavaScript JavaScript Statements JavaScript and HTML forms.

Slides:



Advertisements
Similar presentations
JavaScript FaaDoOEngineers.com FaaDoOEngineers.com.
Advertisements

Introduction to JavaScript
Lesson 12- Unit L Programming Web Pages with JavaScript.
SERVER web page repository WEB PAGE instructions stores information and instructions BROWSER retrieves web page and follows instructions Server Web Server.
MSc. Publishing on WWW JavaScript. What is JavaScript? A scripting language devised by Netscape Adds functionality to web pages by: Embedding code into.
JavaScript- Introduction. What it is and what it does? What it is? It is NOT Java It is NOT Server-side programming Users can see code It is a client-side.
AdvWeb-1/29 DePaul University SNL 262 Advanced Web Page Design Introduction To JavaScript - II Instructor: David A. Lash.
Web Page Behavior IS 373—Web Standards Todd Will.
CS 299 – Web Programming and Design Overview of JavaScript and DOM Instructor: Dr. Fang (Daisy) Tang.
Introduction to JavaScript. Aim To enable you to write you first JavaScript.
JavaScript CMPT 281. Outline Introduction to JavaScript Resources What is JavaScript? JavaScript in web pages.
Javascript and the Web Whys and Hows of Javascript.
4.1 JavaScript Introduction
JavaScript and The Document Object Model MMIS 656 Web Design Technologies Acknowledgements: 1.Notes from David Shrader, NSU GSCIS 2.Some material adapted.
JavaScript Teppo Räisänen LIIKE/OAMK HTML, CSS, JavaScript HTML defines the structure CSS defines the layout JavaScript is used for scripting It.
CS346 - Javascript 1, 21 Module 1 Introduction to JavaScript CS346.
HTML Forms and Scripts. Session overview What are forms? Static vs dynamic Client-side scripts –JavaScript.
Scripting Languages.
 2003 Prentice Hall, Inc. All rights reserved. CHAPTER 3 JavaScript 1.
Introduction to JavaScript MIS 403 Classifications of Languages High-Level vs Low LevelHigh-Level vs Low Level –Remember that Information Technology.
JavaScript Defined DOM (Document Object Model) General Syntax Body vs. Head Variables Math & Logic Selection Functions & Events Loops Animation Getting.
SEG3210 DHTML Tutorial. DHTML DHTML is a combination of technologies used to create dynamic and interactive Web sites. –HTML - For creating text and image.
Bridges To Computing General Information: This document was created for use in the "Bridges to Computing" project of Brooklyn College. You are invited.
SEG3210 DHTML Tutorial. DHTML DHTML is a combination of technologies used to create dynamic and interactive Web sites. –HTML - For creating text and image.
Client Scripting1 Internet Systems Design. Client Scripting2 n “A scripting language is a programming language that is used to manipulate, customize,
What is Java Script? An extension to HTML. An extension to HTML. Allows authors to incorporate some functionality in their web pages. (without using CGI.
Javascript. Outline Introduction Fundamental of JavaScript Javascript events management DOM and Dynamic HTML (DHTML)
Introduction to Applets CS 3505 Client Side Scripting with applets.
INTRODUCTION TO JAVASCRIPT AND DOM Internet Engineering Spring 2012.
An Introduction to JavaScript Summarized from Chapter 6 of “Web Programming: Building Internet Applications”, 3 rd Edition.
Extending HTML CPSC 120 Principles of Computer Science April 9, 2012.
 2003 Prentice Hall, Inc. All rights reserved. CHAPTER 3 JavaScript 1.
Dynamic Web Pages & JavaScript. Dynamic Web Pages Dynamic = Change Dynamic Web Pages are web pages that change. More than just moving graphics around.
Introduction.  The scripting language most often used for client-side web development.  Influenced by many programming languages, easier for nonprogrammers.
44238: Dynamic Web-site Development Client Side Programming Ian Perry Room:C48 Extension:7287
Overview of Form and Javascript fundamentals. Brief matching exercise 1. This is the software that allows a user to access and view HTML documents 2.
1 A Balanced Introduction to Computer Science David Reed, Creighton University ©2005 Pearson Prentice Hall ISBN X Chapter 4 JavaScript and.
Sahar Mosleh California State University San MarcosPage 1 JavaScript Basic.
ECA 225 Applied Interactive Programming1 ECA 225 Applied Online Programming basics.
By Tharith Sriv. To write a web page you use: HHTML (HyperText Markup Language), AASP (Active Server Page), PPHP (HyperText Preprocessor), JJavaScript,
JavaScript Introduction.  JavaScript is a scripting language  A scripting language is a lightweight programming language  A JavaScript can be inserted.
4. Javascript M. Udin Harun Al Rasyid, S.Kom, Ph.D Lab Jaringan Komputer (C-307) Desain.
JavaScript Defined DOM (Document Object Model) General Syntax Body vs. Head Variables Math & Logic Selection Functions & Events Loops Animation Getting.
CIS 3.5 Lecture 2.3 "Introduction to JavaScript".
JavaScript 101 Introduction to Programming. Topics What is programming? The common elements found in most programming languages Introduction to JavaScript.
Javascript Overview. What is Javascript? May be one of the most popular programming languages ever Runs in the browser, not on the server All modern browsers.
Document Object Model Nasrullah. DOM When a page is loaded,browser creates a Document Object Model of the Page.
1 CSC160 Chapter 1: Introduction to JavaScript Chapter 2: Placing JavaScript in an HTML File.
Javascript Basic Concepts Presentation By: Er. Sunny Chanday Lecturer CSE/IT RBIENT.
CGS 3066: Web Programming and Design Spring 2016 Introduction to JavaScript.
JavaScript: A short introduction Joseph Lee Created by Joseph Lee.
Web Programming Java Script-Introduction. What is Javascript? JavaScript is a scripting language using for the Web. JavaScript is a programming language.
Brief Look InTo JavaScript Dr. Thomas Hicks Computer Science Department Trinity University.
Javascript Javascript The JavaScript Programming Language – Scripting Languages Executed by an interpreter contained within.
Introduction to JavaScript
Javascript and Dynamic Web Pages: Client Side Processing
Introduction to JavaScript
Applied Component I Unit II Introduction of java-script
Unit M Programming Web Pages with
Chapter 5 Scripting Language
Chapter 5 Scripting Language
4. Javascript Pemrograman Web I Program Studi Teknik Informatika
JavaScript Introduction
DHTML Javascript Internet Technology.
Introduction to JavaScript
DHTML Javascript Internet Technology.
Introduction to JavaScript
Introduction to JavaScript
JavaScript is a scripting language designed for Web pages by Netscape.
Brief Look InTo JavaScript
Presentation transcript:

Introduction to JavaScript

Introduction What is it? How does it work? What is Java? Learning JavaScript JavaScript Statements JavaScript and HTML forms

What is JavaScript? Browsers have limited functionality Text, images, tables, frames JavaScript allows for interactivity Browser/page manipulation Reacting to user actions A type of programming language Easy to learn Developed by Netscape Now a standard exists – standards/ECMA-262.HTM

JavaScript Allows Interactivity Improve appearance Especially graphics Visual feedback Site navigation Perform calculations Validation of input Other technologies javascript.internet.com

How Does It Work? Embedded within HTML page View source Executes on client Fast, no connection needed once loaded Simple programming statements combined with HTML tags Interpreted (not compiled) No special tools required

What is Java? Totally different A full programming language Much harder! A compiled language Independent of the web Sometimes used together

Learning JavaScript Special syntax to learn Learn the basics and then use other people's (lots of free sites) Write it in a text editor, view results in browser You need to revise your HTML You need patience and good eyesight!

JavaScript Statements My Page document.write('This is my first  JavaScript Page'); Note the symbol for line continuation

JavaScript Statements My Page document.write(' This is my first  JavaScript Page '); HTML written inside JavaScript

JavaScript Statements My Page My Page <a href="myfile.html" onMouseover="window.alert('Hello');"> My Page JavaScript written inside HTML An Event

Example Statements window.prompt('Enter your name:',''); Another event Note quotes: " and '

HTML Forms and JavaScript JavaScript is very good at processing user input in the web browser HTML elements receive input Forms and form elements have unique names Each unique element can be identified Uses JavaScript Document Object Model (DOM)

Naming Form Elements in HTML Name: Phone:

Forms and JavaScript document.formname.elementname.value Thus: document.addressform.yourname.value document.addressform.phone.value document.addressform. .value

Using Form Data Personalising an alert box Enter your name:

Tips Check your statements are on one line Check your " and ' quotes match Take care with capitalisation Lay it out neatly - use tabs Remember  in the workbook denotes a continuing line Be patient Presentation slides adapted from scom.hud.ac.uk/scomsjw/Web%20Authoring%20Module/Lecture%20Slides/introjs.ppt