hasChildNodes method
[This documentation is preliminary and is subject to change.]
Returns a value that indicates whether the object has children.
![]() |
Syntax
object.hasChildNodes()Standards information
Parameters
This method has no parameters.
Return value
Type: BooleanReturns one of the following possible values:| Return value | Description |
|---|---|
|
The object contains HTML Elements or TextNode objects. |
|
The object does not contain HTML Elements or TextNodes. |
Remarks
If the object contains HTML Elements or TextNodes, they can be accessed from the childNodes collection.
In Microsoft Internet Explorer 6, This method now applies to the attribute object.
See also
- a
- abbr
- acronym
- address
- applet
- area
- attribute
- b
- base
- baseFont
- bdo
- big
- blockQuote
- body
- br
- button
- caption
- center
- cite
- code
- col
- colGroup
- comment
- dd
- del
- dfn
- dir
- div
- dl
- dt
- em
- embed
- fieldSet
- font
- form
- frame
- frameSet
- head
- hn
- hr
- html
- i
- iframe
- img
- input type=button
- input type=checkbox
- input type=file
- input type=image
- input type=password
- input type=radio
- input type=reset
- input type=submit
- input type=text
- ins
- kbd
- label
- legend
- li
- link
- listing
- map
- marquee
- menu
- nextID
- ol
- option
- p
- plainText
- pre
- q
- s
- samp
- script
- select
- small
- span
- strike
- strong
- sub
- sup
- table
- tBody
- td
- textArea
- tFoot
- th
- tHead
- title
- tr
- tt
- u
- ul
- var
- xmp
- About the W3C Document Object Model
Build date: 2/14/2012
