DHTML Javascript Internet Technology.

Slides:



Advertisements
Similar presentations
Chapter 7 JavaScript: Introduction to Scripting. Outline Simple Programs Objects and Variables Obtaining User Input with prompt Dialogs – –Dynamic Welcome.
Advertisements

Chapter 08: Adding Adding Interactivity Interactivity With With Behaviors Behaviors By Bill Bennett Associate Professor MSJC CIS MVC.
JavaScript FaaDoOEngineers.com FaaDoOEngineers.com.
JavaScript and the DOM Les Carr COMP3001 Les Carr COMP3001.
The Web Warrior Guide to Web Design Technologies
COMPSCI 345 / SOFTENG 350 TUTORIAL WEEK 8 | SAM KAVANAGH.
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.
JavaScript 101 Lesson 5: Introduction to Events. Lesson Topics Event driven programming Events and event handlers The onClick event handler for hyperlinks.
Chapter 9 Introduction to the Document Object Model (DOM) JavaScript, Third Edition.
Introduction to Javascript. Web Page Technologies To create Web Page documents, you use: To create Web Page documents, you use: HTML – contents and structures.
JavaScript Teppo Räisänen LIIKE/OAMK HTML, CSS, JavaScript HTML defines the structure CSS defines the layout JavaScript is used for scripting It.
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.
Event Handlers CS101 Introduction to Computing. Learning Goals Learn about event handlers Determine how events are useful in JavaScript Discover where.
Bridges To Computing General Information: This document was created for use in the "Bridges to Computing" project of Brooklyn College. You are invited.
Generations of Programming Languages First generation  Machine Language Second Generation  Assembly Language Third Generation  Procedural language such.
CNIT 133 Interactive Web Pags – JavaScript and AJAX JavaScript Environment.
JavaScript 1. What is JavaScript? JavaScript allows web authors to create dynamic pages that react to user interaction. It is an Object-based because.
Lecture 11 – DOM Scripting SFDV3011 – Advanced Web Development Reference: 1.
DHTML: Dynamic HTML Internet Technology1. What is DHTML? A collection of enhancements to HTML ► To create dynamic and interactive websites Combination.
SEG3210 DHTML Tutorial. DHTML DHTML is a combination of technologies used to create dynamic and interactive Web sites. –HTML - For creating text and image.
Working with Objects Creating a Dynamic Web Page.
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)
Flash & JavaScript Mariela Hristova October 19, 2004 INF 385E – Fall 2004 – School of Information.
INTRODUCTION TO JAVASCRIPT AND DOM Internet Engineering Spring 2012.
TUTORIAL 10: PROGRAMMING WITH JAVASCRIPT Session 2: What is JavaScript?
JavaScript - A Web Script Language Fred Durao
Cs332a_chapt10.ppt CS332A Advanced HTML Programming DHTML Dynamic Hypertext Markup Language A term describing a series of technologies Not a stand-a-lone.
TOPIC II Dynamic HTML Prepared by: Nimcan Cabd Cali.
COS 125 DAY 20. Agenda Assignment 8 not corrected yet Assignment 9 posted  Due April 16 New course time line Discussion on Scripts 
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".
Web Programming Overview. Introduction HTML is limited - it cannot manipulate data How Web pages are extended (include): –Java: an object-oriented programming.
Javascript Basic Concepts Presentation By: Er. Sunny Chanday Lecturer CSE/IT RBIENT.
JavaScript and Ajax (JavaScript Environment) Week 6 Web site:
Web Programming Java Script-Introduction. What is Javascript? JavaScript is a scripting language using for the Web. JavaScript is a programming language.
SE-2840 Dr. Mark L. Hornick 1 Dynamic HTML Handling events from DOM objects.
Introduction to.
CGS 3066: Web Programming and Design Spring 2017
DHTML.
Java Script Introduction. Java Script Introduction.
Week 3: Introduction to Javascript
CIIT-Human Computer Interaction-CSC456-Fall-2015-Mr
Week 4: Introduction to Javascript
JavaScript is a programming language designed for Web pages.
JavaScript Event Handling.
Intro to JavaScript CS 1150 Spring 2017.
Web Development & Design Foundations with HTML5 7th Edition
Introduction to JavaScript
JavaScript Introduction
A second look at JavaScript
Your 1st Programming Assignment
DynamicHTML Cascading Style Sheet Internet Technology.
DHTML Javascript Internet Technology.
JavaScript Defined General Syntax Body vs. Head Variables Math & Logic
DynamicHTML Cascading Style Sheet Internet Technology.
Introduction to DHTML, the DOM, JS review
Introduction to JavaScript
Tutorial 10: Programming with javascript
JavaScript Basics What is JavaScript?
JavaScript is a scripting language designed for Web pages by Netscape.
An Introduction to JavaScript
Introduction to Programming and JavaScript
CNIT 133 Interactive Web Pags – JavaScript and AJAX
Web Programming and Design
Week 5: Recap and Portfolio Site
Web Programming and Design
Web Programming and Design
Presentation transcript:

DHTML Javascript Internet Technology

What is DHTML? A collection of enhancements to HTML Combination of 11/13/2018 What is DHTML? A collection of enhancements to HTML To create dynamic and interactive websites Combination of Static Markup language (e.g., HTML) Client-side Scripting language (e.g., JavaScript) Presentation Definition Language (e.g., CSS) Document Object Model Defines the object-oriented model of a document  To allow programs to manipulate content/structure/style of documents  Example Internet Technology

Document Object Model World Wide Web Consortium (W3C) standard 11/13/2018 Document Object Model World Wide Web Consortium (W3C) standard A standard for accessing/updating documents e.g., Core DOM, XML DOM, HTML DOM HTML DOM Object model & programming interface for HMTL Defines Objects  HTML elements Properties  Values (e.g., text) Methods  Actions (e.g. add/delete/change) Events  User Interaction (e.g., mouse click) Javascript with HTML DOM  React to HTML events Change/add/remove HTML elements & attributes Change CSS styles  Examples: #1, #2 Internet Technology

JavaScript A light-weight, client-side programming language 11/13/2018 JavaScript A light-weight, client-side programming language Designed to add interactivity to HTML React to events (e.g., user action)  onClick, onFocus, onBlur, onMouseOver Create dynamic content  Generate HTML codes on the fly Validate data  Do simple calculations on the fly, manipulate forms Embedded in the HTML code Relatively easy to learn & use Every HTML element, document and browser Window are Objects Objects have properties that can be manipulated to control document appearance, content and browser behavior Event handlers can provide interaction Syntax: <ELEMENT EVENT=“JAVASCRIPT”> e.g., <button onClick=“alert(‘Hello, World!’)”>Click It</button>  Example Internet Technology

How to write JavaScript 11/13/2018 How to write JavaScript In an external file Add a link to the external javascript file in the head section Old: <script type=“text/javascript” src=“myjslib.js”></script> New: <script src=“myjslib.js”></script> Advantages: HTML/JS separation, code reuse, faster loading when cached Inside <head></head> Starts with <script > and ends with </script> // starts a comment till the end of line /* and */ for multi-line comments In Body section Place the code at the bottom for faster loading  Example Internet Technology

How to write JavaScript 11/13/2018 How to write JavaScript JavaScript is Case-Sensitive JavaScript Statements End with semicolon (optional) OR end-of line. e.g. document.write(“Hello, World!”); Use var to declare variables Use operators (e.g., =, +, -, *, /) to manipulate values. Use function to declare functions <script> function message(txt) { var label = “Warning”; alert = label + “: “ + txt; } </script> <a href=“#” onMouseOver=“message(‘Hello’);”>  Example Internet Technology

JavaScript: Events & Objects 11/13/2018 JavaScript: Events & Objects Events User actions that trigger JavaScript OnClick: A mouse click OnMouseOver: A mouse over an HTML element OnLoad: Page loading Objects Things that have properties and methods Properties Values associated with an object e.g., String object has “length” property Methods e.g., String object has “toLowercase” property Example: JavaScript & CSS Example: iframe navigation #1, #2, #3 Internet Technology