Results 1 to 4 of 4

Thread: referencing child element of list item

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Sencha User
    Join Date
    May 2012
    Vote Rating

    Default Answered: referencing child element of list item

    Ok, I'm sick that I have to ask this but I can't waste anymore time on it. I have a simple list with an 'itemtap' listener. Within each list item I have a hidden div element that I want to show when the list item is clicked. Baby stuff. But I can't figure out how to reference the element within the list item....

    The itemtap function is simply:

    function(list, index, element, event) {
   stuff here
    So if each list item is:

        <h3>Tom Hanks</h3>
        <div class="hiddenDiv">you can't see this</div>
    What is the proper way to access that div.hiddenDiv within the itemtap function and show it? I tried things like:'element.hiddenDiv').show()'element>.hiddenDiv').show()

    ...and about a million other things. Sorry for such a dumb question, but I'm just sick of wasting time on this. Thanks so much!

  2. Got it! Good grief!!!!


    I'm not even going to ask how to determine if it's visible and then hide it again. Where's jQuery's toggle() when you need it???

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts