13_DOM_Partie_2 - CSI 3540 Structures, techniques et normes...

Info iconThis preview shows pages 1–9. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: CSI 3540 Structures, techniques et normes du Web Saturday, March 6, 2010 Objectif: Bien comprendre le modle objet de document (DOM HTML) ; lAPI permettant JavaScript (et aux autres langages) de manipuler la page courante de lagent utilisateur Lectures: Web Technologies (2007) 5 pages 268-306 JavaScript, documents XHTML, CSS 2 et DOM Saturday, March 6, 2010 DOM - Quest-ce que cest? Laissons parler les auteurs de la spcifcation : (...) une interface indpendante de la plateforme et du langage qui permet aux programmes et aux scripts l' accs et la mise jour dynamique du contenu et de la structure des documents . Saturday, March 6, 2010 hasAttributes() hasChild( Node n ) insertBefore( Node newNode, Node aNode ) removeChild( Node aNode ) replaceChild( Node newNode, Node aNode ) #ELEMENT_NODE #ATTRIBUTE_NODE #TEXT_NODE #COMMENT_NODE #DOCUMENT_NODE #DOCUMENT_TYPE_NODE nodeType nodeName parentNode childNodes previousSibling nextSibling attributes Node < !DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd " > < title > Mon premier document </ title > < p > Hello world! </ p > < head > </ head > < body > </ body > < html xmlns = "http://www.w3.org/1999/xhtml " lang = fr-CA > </ html > html body head title p Saturday, March 6, 2010 Principaux objets hasAttributes() hasChild( Node n ) insertBefore( Node, Node ) removeChild( Node ) replaceChild( Node, Node ) #ELEMENT_NODE #ATTRIBUTE_NODE #TEXT_NODE #COMMENT_NODE #DOCUMENT_NODE #DOCUMENT_TYPE_NODE nodeType nodeName parentNode childNodes previousSibling nextSibling attributes Node createElement( String ) createTextNode( String ) getElementById( String ) getElementsByTagName( String ) doctype documentElement title body URL referrer ... document getAttribute( String ) setAttribute( String, String ) removeAttribute( String ) hasAttribute( String ) getElementsByTagName( String ) tagName Element data Text Principaux objets hasAttributes() hasChild( Node n ) insertBefore( Node, Node ) removeChild( Node ) replaceChild( Node, Node ) #ELEMENT_NODE #ATTRIBUTE_NODE #TEXT_NODE #COMMENT_NODE #DOCUMENT_NODE #DOCUMENT_TYPE_NODE nodeType nodeName parentNode childNodes previousSibling nextSibling attributes Node createElement( String ) createTextNode( String ) getElementById( String ) getElementsByTagName( String ) doctype documentElement title body URL referrer ... document getAttribute( String ) setAttribute( String, String ) removeAttribute( String ) hasAttribute( String ) getElementsByTagName( String ) tagName Element data Text Saturday, March 6, 2010 Saturday, March 6, 2010 Webkit Engin pour XML , XHTML , CSS , XSLT , JavaScript et DOM Code source libre Semble suivre les standards W3C Saturday, March 6, 2010 Webkit Rejeton des bibliothques de programmes de KDE (Systme de fentrage pour Linux) Apple lutilise pour Safari , Dashboard , Mail , mais aussi l iPhone et l iPod Touch Navigateur...
View Full Document

Page1 / 84

13_DOM_Partie_2 - CSI 3540 Structures, techniques et normes...

This preview shows document pages 1 - 9. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online