SlideShare uma empresa Scribd logo
1 de 19
Introduction to DHTML
        Session 13

        Session 13
Objectives
   DHTML.
   Events.
Need for DHTML
   Static pages that are created using HTML and
    CSS concentrate more on the presentation
    layout of the web page. These pages are not
    dynamic by nature. They are not updated.
   Dynamic web pages are more attractive and
    sophisticated web pages. They provide the user
    with the updated content. In addition, can
    create a user interface that allows to display
    new content without downloading additional
    documents from web server.
DHTML
   DHTML provides an easy way for creating dynamic and
    interactive web pages. It allows to create web pages that
    evaluates and responds to user inputs. Can add animation
    effects and generate a link to the database.
   The HTML elements are automatically reformatted to display
    the visual affects and other dynamic changes. For every
    change that is carried out, DHTML does not reload or load the
    document again, but it carries out the changes at the user’s
    computer. Thus, the user does not have to wait to view the
    modifications.
   DHTML composes of various web technologies that can be
    used together to generate more interactive web pages.
            DHTML = CSS + JavaScript + DOM + HTML
DHTML features
   DHTML allows you to create interactive web pages without having
    to compromise on its presentation. DHTML provides various features
    for effective development of dynamic web pages.
   Some feature of DHTML:
    1.   Dynamic style: Using style sheets, we can specify the color,
       style or size of the page content. We can change the style of
       the page without having to return to web server  reduce the
       time-consuming.
    2. Dynamic content: We can change the contents of web page
       after they are displayed in response to user input or events like
       a mouse click.
    3. Real-time positioning: We can specify the exact position (either
       absolute or relative), in terms of x and y co-ordinates. Once
       page is rendered, we can move the elements on the page,
       making it dynamic.
DHTML features….
   Some feature of DHTML:
    4.    Font download: are a feature that allows us to insert our choice
          fonts in the web page. This is an important feature, because if
          the specified fonts are not available on the user’s machine, the
          browser defaults to available our fonts.
    5.    Dynamic binding: We can bind the table in the web page to a
          database. When the web page is loaded, the data from the
          database on the server is displayed in the table.
    6.    Scripting: We can write scripts to change the style and content
          of the web page. This script is inserted in the web page. The
          browser interprets the script whenever the page displayed.
DOM
   DHTML provides an object model that represents a
    collection of elements that are used by the scripts to
    grammatically access and manipulate the web page. This
    object model is referred as Document Object Model
    (DOM). DHTML DOM refers the different elements
    contained within the web page as objects. It is a platform
    independent object model that allows the scripts to
    access the HTML and CSS elements.
   DHTML DOM provides full support to events triggered by
    the user. This allows responding to user’s input and to
    generate better interactivity with much ease.
DHTML objects
   Every element contained within a web page is referred as
    an object. The DHTML objects allow you to access and
    manipulate the element by using the different properties
    and methods.
   Some of DHTML objects:
       a: specifies the beginning and end of a hypertext link.
       body: specifies the start and end of the body of the document.
       div: divides a web page into multiple sections, where each section
        can render other HTML elements.
       document: represents the entire HTML document.
       form: Specifies a container for other controls.
       frame: specifies a frame within a frameset.
       frameset: specifies a frameset that can hold multiple frames.
       html: specifies the HTML elelements.
DHTML objects
   Some of DHTML objects:
       img: specifies an image or video clip to be embedded in the
        document.
       input: creates different form input controls.
       li: specifies a list item.
       link: specifies a link between the existing document and external
        document.
       span: Specifies an inline element to apply styles to a part of the
        text.
       table: specifies that the content should be displayed in a table.
       td: specifies the data to be displayed in a table cell.
       tr: specifies a table row.
Event
   An event occurs when the user interacts with the web
    page. Some of the commonly generated events are
    mouse clicks, key strokes, and so on.
   The process of handling these events is known as event
    handling. Event handling is process of specifying actions
    to be performed when an event occurs. This is done by
    using an event handler.
   The event handler is a scripting code or a function that
    defines the actions to be performed when the event
    triggered.
   When an event occurs, an event handler function that is
    associated with the specific event is invoked.
Event Bubbling
   Event bubbling is a mechanism that allows you to
    specify a common event handler for all child
    elements. This means that the parent element
    handles all events generated by the child elements.
   Life circle of an event:
     1.   The user performs an action to raise an event.
     2.   The event object is updated to determine the
          event state.
     3.   The event is fired.
     4.   The event bubbling occurs as the event
          bubbles through the elements of the
          hierarchy.
     5.   The event handler is invoked that performs
          the specified actions.
Keyboard Event
   Keyboard events are the events that occur when a
    key or a combination of keys are pressed or released
    from a keyboard. Theses events occur for all keys of
    keyboard.

   Some keyboard events:
       onKeyDown: Occurs when a key is pressed down.
       onKeyUp: Occurs when a key is released.
       onKeyPress: Occurs when a key is pressed and released.
keyboard event - Demo




Demo: S13_KeyboardEvent.html
Mouse Event
   Mouse events are the events that occur when the user
    uses mouse on the elements.
   Some mouse events:
       onMouseDown: Occurs when the mouse button is pressed.
       onMousUp: Occurs when the mouse button is released.
       onMouseClick: Occurs when the mouse button is clicked.
       onDblClick: Occurs when the mouse button is double-clicked.
       onMouseMove: Occurs when the mouse pointer is moved from
        one location to other.
       onMouseOver: Occurs when the mouse pointer is moved over
        element.
       onMouseOut: Occurs when the mouse pointer is moved out of
        the element.
mouse event - Demo


                          onMouseOver




                          onClick




Demo: S13_KeyboardEvent.html
Focus and selection Event
   The focus events determine the activation of various
    elements that use the INPUT element. It allows you to
    set or reset focus for different INPUT elements.
   The selection events occur when an element is selected.
   Some events:
       onFocus: Occurs when an element receives focus.
       onBlur: Occurs when an element loses the focus.
       onSelectStart: Occurs when the selection of an element
        starts.
       onSelect: Occurs when the present selection changes.
       onDragStart: Occurs when the selected element is moved.
mouse event - Demo



                           onFocus




Demo: S13_KeyboardEvent.html
Summary
   DHTML allows to create a dynamic web pages.
   DHTML is combination a DOM, CSS, HTML and
    Javascript.
   It provides a set of functionalities to handle a
    user - generated event
   Some of the features of DHTML:
       Dynamic style
       Dynamic contents
       Real-time positioning
Summary
   Event occur when the user interacts the web
    page
   The process of handling these events is known
    event – handling.
   Event – handling is a process of specifying
    actions to be performed when an event occurs.

Mais conteúdo relacionado

Mais procurados (20)

Dhtml ppt (2)
Dhtml ppt (2)Dhtml ppt (2)
Dhtml ppt (2)
 
Dynamic HTML (DHTML)
Dynamic HTML (DHTML)Dynamic HTML (DHTML)
Dynamic HTML (DHTML)
 
Dhtml
DhtmlDhtml
Dhtml
 
introduction to the document object model- Dom chapter5
introduction to the document object model- Dom chapter5introduction to the document object model- Dom chapter5
introduction to the document object model- Dom chapter5
 
15. session 15 data binding
15. session 15   data binding15. session 15   data binding
15. session 15 data binding
 
Html and dhtml
Html and dhtmlHtml and dhtml
Html and dhtml
 
Document Object Model
Document Object ModelDocument Object Model
Document Object Model
 
Dom structure
Dom structureDom structure
Dom structure
 
Introduction to DOM
Introduction to DOMIntroduction to DOM
Introduction to DOM
 
Document Object Model
Document Object ModelDocument Object Model
Document Object Model
 
Understanding the dom by Benedict Ayiko
Understanding the dom by Benedict AyikoUnderstanding the dom by Benedict Ayiko
Understanding the dom by Benedict Ayiko
 
Document Object Model
Document Object ModelDocument Object Model
Document Object Model
 
Document object model(dom)
Document object model(dom)Document object model(dom)
Document object model(dom)
 
DYNAMIC HYPERTEXT MARKUP LANGUAGE (DHTML) & CSS WITH Application of JavaScript
DYNAMIC HYPERTEXT MARKUP LANGUAGE (DHTML) & CSS WITH Application of JavaScriptDYNAMIC HYPERTEXT MARKUP LANGUAGE (DHTML) & CSS WITH Application of JavaScript
DYNAMIC HYPERTEXT MARKUP LANGUAGE (DHTML) & CSS WITH Application of JavaScript
 
An Introduction to the DOM
An Introduction to the DOMAn Introduction to the DOM
An Introduction to the DOM
 
Web Designing
Web DesigningWeb Designing
Web Designing
 
Document object model
Document object modelDocument object model
Document object model
 
Html n CSS
Html n CSSHtml n CSS
Html n CSS
 
Dom(document object model)
Dom(document object model)Dom(document object model)
Dom(document object model)
 
Document Object Model
Document Object ModelDocument Object Model
Document Object Model
 

Destaque

Destaque (8)

Dynamic HTML
Dynamic HTMLDynamic HTML
Dynamic HTML
 
Dynamic HTML Event Model
Dynamic HTML Event ModelDynamic HTML Event Model
Dynamic HTML Event Model
 
Beginners css tutorial for web designers
Beginners css tutorial for web designersBeginners css tutorial for web designers
Beginners css tutorial for web designers
 
CSS Tutorial
CSS TutorialCSS Tutorial
CSS Tutorial
 
DHTML - Events & Buttons
DHTML - Events  & ButtonsDHTML - Events  & Buttons
DHTML - Events & Buttons
 
Introduction to Cascading Style Sheets (CSS)
Introduction to Cascading Style Sheets (CSS)Introduction to Cascading Style Sheets (CSS)
Introduction to Cascading Style Sheets (CSS)
 
Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSS
 
cascading style sheet ppt
cascading style sheet pptcascading style sheet ppt
cascading style sheet ppt
 

Semelhante a 13. session 13 introduction to dhtml

Digital Marketing Company
Digital Marketing CompanyDigital Marketing Company
Digital Marketing CompanyPayal9675
 
Less03 2 e_testermodule_2
Less03 2 e_testermodule_2Less03 2 e_testermodule_2
Less03 2 e_testermodule_2Suresh Mishra
 
Web components
Web componentsWeb components
Web componentsMohd Saeed
 
Web Performance Tips
Web Performance TipsWeb Performance Tips
Web Performance TipsRavi Raj
 
WEB TECHNOLOGY Unit-4.pptx
WEB TECHNOLOGY Unit-4.pptxWEB TECHNOLOGY Unit-4.pptx
WEB TECHNOLOGY Unit-4.pptxkarthiksmart21
 
Accessible web applications
Accessible web applications Accessible web applications
Accessible web applications Steven Faulkner
 
06 win forms
06 win forms06 win forms
06 win formsmrjw
 
How Browsers Work -By Tali Garsiel and Paul Irish
How Browsers Work -By Tali Garsiel and Paul IrishHow Browsers Work -By Tali Garsiel and Paul Irish
How Browsers Work -By Tali Garsiel and Paul IrishNagamurali Reddy
 
Client side scripting using Javascript
Client side scripting using JavascriptClient side scripting using Javascript
Client side scripting using JavascriptBansari Shah
 
Reactive web
Reactive webReactive web
Reactive webdega1999
 
Flex3 Deep Dive Final
Flex3 Deep Dive FinalFlex3 Deep Dive Final
Flex3 Deep Dive FinalRJ Owen
 
Java script browser objects 1
Java script browser objects 1Java script browser objects 1
Java script browser objects 1H K
 
Unit ii java script and xhtml documents and dynamic documents with javascript
Unit ii java script and xhtml documents and dynamic documents with javascriptUnit ii java script and xhtml documents and dynamic documents with javascript
Unit ii java script and xhtml documents and dynamic documents with javascriptzahid7578
 

Semelhante a 13. session 13 introduction to dhtml (20)

Vb.net and .Net Framework
Vb.net and .Net FrameworkVb.net and .Net Framework
Vb.net and .Net Framework
 
Digital Marketing Company
Digital Marketing CompanyDigital Marketing Company
Digital Marketing Company
 
Less03 2 e_testermodule_2
Less03 2 e_testermodule_2Less03 2 e_testermodule_2
Less03 2 e_testermodule_2
 
WP - Unit I.ppt
WP - Unit I.pptWP - Unit I.ppt
WP - Unit I.ppt
 
Web components
Web componentsWeb components
Web components
 
WPF Fundamentals
WPF FundamentalsWPF Fundamentals
WPF Fundamentals
 
J query
J queryJ query
J query
 
Web Performance Tips
Web Performance TipsWeb Performance Tips
Web Performance Tips
 
JS basics
JS basicsJS basics
JS basics
 
WEB TECHNOLOGY Unit-4.pptx
WEB TECHNOLOGY Unit-4.pptxWEB TECHNOLOGY Unit-4.pptx
WEB TECHNOLOGY Unit-4.pptx
 
Accessible web applications
Accessible web applications Accessible web applications
Accessible web applications
 
06 win forms
06 win forms06 win forms
06 win forms
 
How Browsers Work -By Tali Garsiel and Paul Irish
How Browsers Work -By Tali Garsiel and Paul IrishHow Browsers Work -By Tali Garsiel and Paul Irish
How Browsers Work -By Tali Garsiel and Paul Irish
 
Javascript
Javascript Javascript
Javascript
 
Client side scripting using Javascript
Client side scripting using JavascriptClient side scripting using Javascript
Client side scripting using Javascript
 
Reactive web
Reactive webReactive web
Reactive web
 
Flex3 Deep Dive Final
Flex3 Deep Dive FinalFlex3 Deep Dive Final
Flex3 Deep Dive Final
 
Java script browser objects 1
Java script browser objects 1Java script browser objects 1
Java script browser objects 1
 
Advanced Jquery
Advanced JqueryAdvanced Jquery
Advanced Jquery
 
Unit ii java script and xhtml documents and dynamic documents with javascript
Unit ii java script and xhtml documents and dynamic documents with javascriptUnit ii java script and xhtml documents and dynamic documents with javascript
Unit ii java script and xhtml documents and dynamic documents with javascript
 

Mais de Phúc Đỗ

15. session 15 data binding
15. session 15   data binding15. session 15   data binding
15. session 15 data bindingPhúc Đỗ
 
14. session 14 dhtml filter
14. session 14   dhtml filter14. session 14   dhtml filter
14. session 14 dhtml filterPhúc Đỗ
 
12. session 12 java script objects
12. session 12   java script objects12. session 12   java script objects
12. session 12 java script objectsPhúc Đỗ
 
11. session 11 functions and objects
11. session 11   functions and objects11. session 11   functions and objects
11. session 11 functions and objectsPhúc Đỗ
 
10. session 10 loops and arrays
10. session 10   loops and arrays10. session 10   loops and arrays
10. session 10 loops and arraysPhúc Đỗ
 
09. session 9 operators and statements
09. session 9   operators and statements09. session 9   operators and statements
09. session 9 operators and statementsPhúc Đỗ
 
08. session 08 intoduction to javascript
08. session 08   intoduction to javascript08. session 08   intoduction to javascript
08. session 08 intoduction to javascriptPhúc Đỗ
 
07. session 07 adv css properties
07. session 07   adv css properties07. session 07   adv css properties
07. session 07 adv css propertiesPhúc Đỗ
 
06. session 06 css color_andlayoutpropeties
06. session 06   css color_andlayoutpropeties06. session 06   css color_andlayoutpropeties
06. session 06 css color_andlayoutpropetiesPhúc Đỗ
 
05. session 05 introducing css
05. session 05   introducing css05. session 05   introducing css
05. session 05 introducing cssPhúc Đỗ
 
04. session 04 working withformsandframes
04. session 04   working withformsandframes04. session 04   working withformsandframes
04. session 04 working withformsandframesPhúc Đỗ
 
03. session 03 using lists and tables
03. session 03   using lists and tables03. session 03   using lists and tables
03. session 03 using lists and tablesPhúc Đỗ
 
02. session 02 working with html elements
02. session 02   working with html elements02. session 02   working with html elements
02. session 02 working with html elementsPhúc Đỗ
 
01. session 01 introduction to html
01. session 01   introduction to html01. session 01   introduction to html
01. session 01 introduction to htmlPhúc Đỗ
 

Mais de Phúc Đỗ (14)

15. session 15 data binding
15. session 15   data binding15. session 15   data binding
15. session 15 data binding
 
14. session 14 dhtml filter
14. session 14   dhtml filter14. session 14   dhtml filter
14. session 14 dhtml filter
 
12. session 12 java script objects
12. session 12   java script objects12. session 12   java script objects
12. session 12 java script objects
 
11. session 11 functions and objects
11. session 11   functions and objects11. session 11   functions and objects
11. session 11 functions and objects
 
10. session 10 loops and arrays
10. session 10   loops and arrays10. session 10   loops and arrays
10. session 10 loops and arrays
 
09. session 9 operators and statements
09. session 9   operators and statements09. session 9   operators and statements
09. session 9 operators and statements
 
08. session 08 intoduction to javascript
08. session 08   intoduction to javascript08. session 08   intoduction to javascript
08. session 08 intoduction to javascript
 
07. session 07 adv css properties
07. session 07   adv css properties07. session 07   adv css properties
07. session 07 adv css properties
 
06. session 06 css color_andlayoutpropeties
06. session 06   css color_andlayoutpropeties06. session 06   css color_andlayoutpropeties
06. session 06 css color_andlayoutpropeties
 
05. session 05 introducing css
05. session 05   introducing css05. session 05   introducing css
05. session 05 introducing css
 
04. session 04 working withformsandframes
04. session 04   working withformsandframes04. session 04   working withformsandframes
04. session 04 working withformsandframes
 
03. session 03 using lists and tables
03. session 03   using lists and tables03. session 03   using lists and tables
03. session 03 using lists and tables
 
02. session 02 working with html elements
02. session 02   working with html elements02. session 02   working with html elements
02. session 02 working with html elements
 
01. session 01 introduction to html
01. session 01   introduction to html01. session 01   introduction to html
01. session 01 introduction to html
 

Último

DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfSeasiaInfotech2
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 

Último (20)

DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdf
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 

13. session 13 introduction to dhtml

  • 1. Introduction to DHTML Session 13 Session 13
  • 2. Objectives  DHTML.  Events.
  • 3. Need for DHTML  Static pages that are created using HTML and CSS concentrate more on the presentation layout of the web page. These pages are not dynamic by nature. They are not updated.  Dynamic web pages are more attractive and sophisticated web pages. They provide the user with the updated content. In addition, can create a user interface that allows to display new content without downloading additional documents from web server.
  • 4. DHTML  DHTML provides an easy way for creating dynamic and interactive web pages. It allows to create web pages that evaluates and responds to user inputs. Can add animation effects and generate a link to the database.  The HTML elements are automatically reformatted to display the visual affects and other dynamic changes. For every change that is carried out, DHTML does not reload or load the document again, but it carries out the changes at the user’s computer. Thus, the user does not have to wait to view the modifications.  DHTML composes of various web technologies that can be used together to generate more interactive web pages. DHTML = CSS + JavaScript + DOM + HTML
  • 5. DHTML features  DHTML allows you to create interactive web pages without having to compromise on its presentation. DHTML provides various features for effective development of dynamic web pages.  Some feature of DHTML: 1. Dynamic style: Using style sheets, we can specify the color, style or size of the page content. We can change the style of the page without having to return to web server  reduce the time-consuming. 2. Dynamic content: We can change the contents of web page after they are displayed in response to user input or events like a mouse click. 3. Real-time positioning: We can specify the exact position (either absolute or relative), in terms of x and y co-ordinates. Once page is rendered, we can move the elements on the page, making it dynamic.
  • 6. DHTML features….  Some feature of DHTML: 4. Font download: are a feature that allows us to insert our choice fonts in the web page. This is an important feature, because if the specified fonts are not available on the user’s machine, the browser defaults to available our fonts. 5. Dynamic binding: We can bind the table in the web page to a database. When the web page is loaded, the data from the database on the server is displayed in the table. 6. Scripting: We can write scripts to change the style and content of the web page. This script is inserted in the web page. The browser interprets the script whenever the page displayed.
  • 7. DOM  DHTML provides an object model that represents a collection of elements that are used by the scripts to grammatically access and manipulate the web page. This object model is referred as Document Object Model (DOM). DHTML DOM refers the different elements contained within the web page as objects. It is a platform independent object model that allows the scripts to access the HTML and CSS elements.  DHTML DOM provides full support to events triggered by the user. This allows responding to user’s input and to generate better interactivity with much ease.
  • 8. DHTML objects  Every element contained within a web page is referred as an object. The DHTML objects allow you to access and manipulate the element by using the different properties and methods.  Some of DHTML objects:  a: specifies the beginning and end of a hypertext link.  body: specifies the start and end of the body of the document.  div: divides a web page into multiple sections, where each section can render other HTML elements.  document: represents the entire HTML document.  form: Specifies a container for other controls.  frame: specifies a frame within a frameset.  frameset: specifies a frameset that can hold multiple frames.  html: specifies the HTML elelements.
  • 9. DHTML objects  Some of DHTML objects:  img: specifies an image or video clip to be embedded in the document.  input: creates different form input controls.  li: specifies a list item.  link: specifies a link between the existing document and external document.  span: Specifies an inline element to apply styles to a part of the text.  table: specifies that the content should be displayed in a table.  td: specifies the data to be displayed in a table cell.  tr: specifies a table row.
  • 10. Event  An event occurs when the user interacts with the web page. Some of the commonly generated events are mouse clicks, key strokes, and so on.  The process of handling these events is known as event handling. Event handling is process of specifying actions to be performed when an event occurs. This is done by using an event handler.  The event handler is a scripting code or a function that defines the actions to be performed when the event triggered.  When an event occurs, an event handler function that is associated with the specific event is invoked.
  • 11. Event Bubbling  Event bubbling is a mechanism that allows you to specify a common event handler for all child elements. This means that the parent element handles all events generated by the child elements.  Life circle of an event: 1. The user performs an action to raise an event. 2. The event object is updated to determine the event state. 3. The event is fired. 4. The event bubbling occurs as the event bubbles through the elements of the hierarchy. 5. The event handler is invoked that performs the specified actions.
  • 12. Keyboard Event  Keyboard events are the events that occur when a key or a combination of keys are pressed or released from a keyboard. Theses events occur for all keys of keyboard.  Some keyboard events:  onKeyDown: Occurs when a key is pressed down.  onKeyUp: Occurs when a key is released.  onKeyPress: Occurs when a key is pressed and released.
  • 13. keyboard event - Demo Demo: S13_KeyboardEvent.html
  • 14. Mouse Event  Mouse events are the events that occur when the user uses mouse on the elements.  Some mouse events:  onMouseDown: Occurs when the mouse button is pressed.  onMousUp: Occurs when the mouse button is released.  onMouseClick: Occurs when the mouse button is clicked.  onDblClick: Occurs when the mouse button is double-clicked.  onMouseMove: Occurs when the mouse pointer is moved from one location to other.  onMouseOver: Occurs when the mouse pointer is moved over element.  onMouseOut: Occurs when the mouse pointer is moved out of the element.
  • 15. mouse event - Demo onMouseOver onClick Demo: S13_KeyboardEvent.html
  • 16. Focus and selection Event  The focus events determine the activation of various elements that use the INPUT element. It allows you to set or reset focus for different INPUT elements.  The selection events occur when an element is selected.  Some events:  onFocus: Occurs when an element receives focus.  onBlur: Occurs when an element loses the focus.  onSelectStart: Occurs when the selection of an element starts.  onSelect: Occurs when the present selection changes.  onDragStart: Occurs when the selected element is moved.
  • 17. mouse event - Demo onFocus Demo: S13_KeyboardEvent.html
  • 18. Summary  DHTML allows to create a dynamic web pages.  DHTML is combination a DOM, CSS, HTML and Javascript.  It provides a set of functionalities to handle a user - generated event  Some of the features of DHTML:  Dynamic style  Dynamic contents  Real-time positioning
  • 19. Summary  Event occur when the user interacts the web page  The process of handling these events is known event – handling.  Event – handling is a process of specifying actions to be performed when an event occurs.