SERVER web page repository WEB PAGE instructions stores information and instructions BROWSER retrieves web page and follows instructions Server Web Server.

Slides:



Advertisements
Similar presentations
1 What is JavaScript? JavaScript was designed to add interactivity to HTML pages JavaScript is a scripting language A scripting language is a lightweight.
Advertisements

Lesson 12- Unit L Programming Web Pages with JavaScript.
Introduction to JavaScript Module 1 Client Side JS Programming M-GO Sponsored By
The Web Warrior Guide to Web Design Technologies
Outline IS400: Development of Business Applications on the Internet Fall 2004 Instructor: Dr. Boris Jukic JavaScript: Introduction to Scripting.
SERVER web page repository WEB PAGE instructions stores information and instructions BROWSER retrieves web page and follows instructions Server Web Server.
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.
Web Page Behavior IS 373—Web Standards Todd Will.
Computer Science 103 Chapter 4 Advanced JavaScript.
Introduction to Javascript. Web Page Technologies To create Web Page documents, you use: To create Web Page documents, you use: HTML – contents and structures.
Inline, Internal, and External FIle
Introduction to JavaScript. Aim To enable you to write you first JavaScript.
JavaScript Teppo Räisänen LIIKE/OAMK HTML, CSS, JavaScript HTML defines the structure CSS defines the layout JavaScript is used for scripting It.
Event-driven Programming
Event Handlers CS101 Introduction to Computing. Learning Goals Learn about event handlers Determine how events are useful in JavaScript Discover where.
SERVER web page repository WEB PAGE instructions stores information and instructions BROWSER retrieves web page and follows instructions Server Web Server.
DHTML: Dynamic HTML Internet Technology1. What is DHTML? A collection of enhancements to HTML ► To create dynamic and interactive websites Combination.
Client Scripting1 Internet Systems Design. Client Scripting2 n “A scripting language is a programming language that is used to manipulate, customize,
Client Side Programming with JavaScript Why use client side programming? Web sides built on CGI programs can rapidly become overly complicated to maintain,
INTRODUCTION TO JAVASCRIPT AND DOM Internet Engineering Spring 2012.
Extending HTML CPSC 120 Principles of Computer Science April 9, 2012.
JavaScript - A Web Script Language Fred Durao
HTML Form Widgets. Review: HTML Forms HTML forms are used to create web pages that accept user input Forms allow the user to communicate information back.
44238: Dynamic Web-site Development Client Side Programming Ian Perry Room:C48 Extension:7287
XP Tutorial 8 Adding Interactivity with ActionScript.
Event-Driven Programming Chapter Page Section: Section or division of an HTML page Generic block element Example: What's the difference between.
JavaScript Introduction.  JavaScript is a scripting language  A scripting language is a lightweight programming language  A JavaScript can be inserted.
1 Chapter 3 – JavaScript Outline Introduction Flowcharts Control Structures if Selection Structure if/else Selection Structure while Repetition Structure.
1 CSC160 Chapter 7: Events and Event Handlers. 2 Outline Event and event handlers onClick event handler onMouseOver event handler onMouseOut event handler.
HTML Overview Part 5 – JavaScript 1. Scripts 2  Scripts are used to add dynamic content to a web page.  Scripts consist of a list of commands that execute.
CIS 3.5 Lecture 2.3 "Introduction to JavaScript".
Web Authoring with Dreamweaver. Unit Objectives  Be able to define keywords: HTML, HTTP (protocol), browser, web server, client/server, tag, attribute,
INTRODUCTION JavaScript can make websites more interactive, interesting, and user-friendly.
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.
Web Programming Overview. Introduction HTML is limited - it cannot manipulate data How Web pages are extended (include): –Java: an object-oriented programming.
Review of HTML and CSS A (very) brief review of some key fundamentals to be aware of in IT-238.
JavaScript Functions. CSS Inheritance Which formatting applies? x y z input { display: block; } input.pref { background:red; } If you have a selector.
SERVER web page repository WEB PAGE instructions stores information and instructions BROWSER retrieves web page and follows instructions Server Web Server.
Document Object Model Nasrullah. DOM When a page is loaded,browser creates a Document Object Model of the Page.
Introduction 1.HTML DOM events allow JavaScript to register different event handlers on elements in an HTML document. 2.Events are normally used in combination.
JavaScript Introduction and Background. 2 Web languages Three formal languages HTML JavaScript CSS Three different tasks Document description Client-side.
JavaScript Events Java 4 Understanding Events Events add interactivity between the web page and the user You can think of an event as a trigger that.
CSC 121 Computers and Scientific Thinking Fall Event-Driven Programming.
CGS 3066: Web Programming and Design Spring 2016 Introduction to JavaScript.
JavaScript and Ajax (JavaScript Environment) Week 6 Web site:
JavaScript Events. Understanding Events Events add interactivity between the web page and the user Events add interactivity between the web page and the.
A little PHP. Enter the simple HTML code seen below.
JavaScript Part 1 Introduction to scripting The ‘alert’ function.
Introduction to.
A little PHP.
Week 3: Introduction to Javascript
Week 4: Introduction to Javascript
JavaScript.
JavaScript.
Introduction to JavaScript
COMP 101 Introduction.
DHTML Javascript Internet Technology.
A second look at JavaScript
COMP 101 Introduction.
WEB PROGRAMMING JavaScript.
DHTML Javascript Internet Technology.
Functions, Regular expressions and Events
Web Design and Development
Events: Changed and Input
Introduction to JavaScript
Tutorial 10: Programming with javascript
Introduction to JavaScript
Introduction to Web programming
Presentation transcript:

SERVER web page repository WEB PAGE instructions stores information and instructions BROWSER retrieves web page and follows instructions Server Web Server Pages Client Browser 1 3 2

 Two places you can change › Browser: JavaScript › Server: php  General rule: › do it in the browser if you can  Why? › Distribute the work › Consider the difference in the time function… Server Web Server Pages Client Browser 1 3 2

HTML Content CSS Presentation JavaScript Behavior

 Simple programming tool  Functions › react to events › read and write HTML elements › dynamic text › compute functions › change pictures  w3schools, codecademy w3schoolscodecademy

 Set of ORDERED instructions  Recipe  Difference between 1. Melt butter 2. Add flour  And 1. Add flour 2. Melt butter

 JavaScript: series of statements  Each statement = instruction step  Always ends with a ;  Consists of › actions › information to act on

 Our first JavaScript statement  Puts up a box that user MUST clear  Can experiment on jsfiddlejsfiddle  Format alert (string);  String › Literal: simply put it in quotation marks  Can use ‘ or “ but must match › Can build up (concatenate) with +

 Different actions on different types of data  Can’t do math on strings  CAN print numbers  Don’t be fooled by that +: does NOT mean add  Strings › Note that “a b “ and ”a b” are DIFFERENT › Inside literals, blanks are significant

1. String 2. Number 3. String and number 4. Added numbers 5. String and added numbers

 Invoke JavaScript and something changes  Invocation occurs when an EVENT happens  Events occur when › User input from mouse or keyboard  Mouse movement  Mouse click  Key presses › HTML elements change (e.g., page loaded)  Simplest event: mouse click ONCLICK

 Attribute that can be added to most any HTML element  Takes a single JavaScript statement.  New element that you might find useful: Click Me!