I was wondering if this is possible with js?
Say you've got several nested <ul> elements, and you'd like to use a small bit of js to assign the "parent" <li>'s a special classname...
So how could you go about getting js to autmatically assign the special classname to the "Parent" <li> shown above?HTML Code:<ul> <li>Child</li> <li>Child</li> <li>Parent <ul> <li>Grandchild</li> <li>Grandchild</li> </ul> </li> <li>Child</li> </ul>



Reply With Quote

Bookmarks