But there is not a possibility by using "getElementByTagName()" or other? Because, which I would like to do, it is to recover all the objects (<p>, <img>, <a>,...) which have an attribute "class" and with "document.body.innerHTML" I do not know how to do that.
@FangJan 22.2004 — #This would find all the <p class="heading"> elements within the element with id="object_id" var oRoot=document.getElementById('object_id'); var oList=oRoot.document.getElementsByName('p'); for(var i=0; i<oList.length; i++) { if(oList[i].getAttribute('class')=="heading") { // do something here } }