Counting child elements

<div id="foo"> <div id="bar"></div> <div id="baz"> <div id="biz"> </div> <span><span> </div> //jQuery code to count child elements $("#foo > div").length

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.