Chapter 14 Dynamic HTML: Event Model - PowerPoint PPT Presentation

Loading...

PPT – Chapter 14 Dynamic HTML: Event Model PowerPoint presentation | free to view - id: d0039-ZDc1Z



Loading


The Adobe Flash plugin is needed to view this content

Get the plugin now

View by Category
About This Presentation
Title:

Chapter 14 Dynamic HTML: Event Model

Description:

14.10 More DHTML Events. Remaining DHTML events and their descriptions ... 14.10 More DHTML Events. 2007 Dr. Natheer Khasawneh. 14.10 More DHTML Events ... – PowerPoint PPT presentation

Number of Views:109
Avg rating:3.0/5.0
Slides: 34
Provided by: beiz
Category:
Tags: html | chapter | dhtml | dynamic | event | model

less

Write a Comment
User Comments (0)
Transcript and Presenter's Notes

Title: Chapter 14 Dynamic HTML: Event Model


1
Chapter 14 - Dynamic HTML Event Model
Outline 14.1 Introduction 14.2 Event
onclick 14.3 Event onload 14.4 Error Handling
with onerror 14.5 Tracking the Mouse with Event
onmousemove 14.6 Rollovers with onmouseover and
onmouseout 14.7 Form Processing with onfocus
and onblur 14.8 More Form Processing with
onsubmit and onreset 14.9 Event Bubbling 14.10
More DHTML Events Online Resource http//www.w3
schools.com/htmldom/dom_obj_event.asp
2
Objectives
  • In this lesson, you will learn
  • To understand the notion of events, event
    handlers and event bubbling.
  • To be able to create event handlers that respond
    to mouse and keyboard events.
  • To be able to use the event object to be made
    aware of and, ultimately, respond to user
    actions.
  • To understand how to recognize and respond to the
    most popular events.

3
14.1  Introduction
  • Event model
  • Scripts can respond to user
  • Content becomes more dynamic
  • Interfaces become more intuitive

4
14.2  Event onclick
  • onClick
  • Invoked when user clicks the mouse on a specific
    item

5
onclick.html(1 of 2)
6
onclick.html(2 of 2)
7
(No Transcript)
8
14.3  Event onload
  • onload event
  • Fires when an element finishes loading
  • Used in the body element
  • Initiates a script after the page loads into the
    client

9
onload.html(1 of 2)
10
onload.html(2 of 2)
11
14.4  Error Handling with onerror
  • onerror event
  • Execute specialized error-handling code
  • The onerror event is triggered when an error
    occurs loading a document or an image.

12
onerror.html(1 of 2)
13
onerror.html(2 of 2)
14
14.5  Tracking the Mouse with Event onmousemove
  • onmousemove
  • Fires repeatedly when the user moves the mouse
    over the Web page
  • Gives position of the mouse

15
onmousemove.html(1 of 2)
16
onmousemove.html(2 of 2)
17
More event object properties
18
14.7  Form Processing with onfocus and onblur
  • onfocus event fires when element gains focus
  • onblur event fires when element loses focus

19
onfocusblur.html(1 of 3)
20
onfocusblur.html(2 of 3)
21
onfocusblur.html(3 of 3)
22
14.8  More Form Processing with onsubmit and
onreset
  • onsubmit and onreset are useful events for
    processing forms

23
onsubmitreset.html(1 of 4)
24
onsubmitreset.html(2 of 4)
25
onsubmitreset.html(3 of 4)
26
onsubmitreset.html(4 of 4)
27
onkeydown Event
  • The onkeydown event occurs when a keyboard key is
    pressed.
  • Internet Explorer uses event.keyCode to retrieve
    the character that was pressed
  • Netscape/Firefox/Opera uses event.which
  • Example onkeydown.html

28
onkeypress Event
  • The onkeydown event occurs when a keyboard key is
    pressed or held down.
  • Internet Explorer uses event.keyCode to retrieve
    the character that was pressed
  • Netscape/Firefox/Opera uses event.which.
  • Example onkeypress.html

29
onKeyUp Event
  • The onkeyup event occurs when a keyboard key is
    released.
  • Example onkeyup.html

30
14.10  More DHTML Events
  • Remaining DHTML events and their descriptions

31
14.10  More DHTML Events
32
14.10  More DHTML Events
33
14.10  More DHTML Events
About PowerShow.com