Adobe 38040334 API Reference - Page 316
elem.isBlockElement, elem.isInlineElement
UPC - 883919090467
View all Adobe 38040334 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 316 highlights
DREAMWEAVER CS3 311 API Reference elem.isBlockElement() Availability Dreamweaver CS3. Description Checks whether the element has an inherent or specified display value of 'block'. Arguments None. Returns A Boolean value indicating whether the object is a block-level element. Example [...] var DOM = dw.getDocumentDOM(); var blocks = DOM.body.getBlockElements(); var next = null; for (var i=0; i < blocks.length; i++){ // next is the node right after blocks[i] next = blocks[i].nextSibling; // if next isn't null AND next is an element node AND next is a block element, // we've met the "second of two consecutive block elements" test. if (next && (next.nodeType == 1) && next.isBlockElement()){ // do something } } [...] elem.isInlineElement() Availability Dreamweaver CS3. Description Checks whether the element has an inherent or specified display value of 'inline'. Arguments None. Returns A Boolean value indicating whether the object is an inline element.