Well id's really should always be unique. But if you really want to do this, try:
alert($('#001').children('#0011').html()); ----- Original Message ----- From: Mark To: jquery-en@googlegroups.com Sent: Friday, June 01, 2007 5:22 PM Subject: [jQuery] Javascript question: Get elementid inside an element Hey, For example take this code: <div id="001"> <div id="0010"> </div> <div id="0011"> </div> </div> Now i want to have the InnerHtml of id 0011 one way to do that is: document.getelementbyid('0011'); But that id COULD be in more places.. (i know it`s not good for id`s.. but in some cases it`s possible) So how do i get the id: 0011 without the document thing? i tried this: var test = document.getelementbyid('001'); alert(test.getelementbyid(0011).InnerHtml); but that isn`t working. I hope someone could help me with this. (above code is not tested) Thanx in favor, Mark