can't select just injected elements

can't select just injected elements

Hello Community,
I'm new to jQuery and jQuery Mobile developing, but I resently desided to give jQuery Mobile a try, rather then developing native android apps.

But I am stuck for over two days now, at the point, that I'm not able to select just injected Elements.
The injecting takes place in the pagebeforechange event wich I register as followed:
  1. $(document).bind( "pagebeforechange", function( e, data ) {
  2.     //recognize right pagechange
  3.     //inject photogallery
  4. }
And the selection takes place in the pageshow event, which I register as followed:

  1. $('').live('pageshow', function(e){console.log('pageshow');
  2.     var currentPage = $(;
  3.     console.log(currentPage.attr('id'));
  4.     var options = {};
  5.     console.log($(" a",;
  6. });
But the last log only shows an empty jQuery Object. But the page is shown right. Therfore I see the elements, that the selector does not select. Both rendered and in the DOM in Opera Dragonfly. And I see the elements when I select the body tag. I even tried just selecting all anchor-elements, or all img-tags but the resently injected weren't selected.
  1. <ul class="gallery" id="10150125627794020">
  2.     <li>
  3.         <a href="https://..." rel="external">
  4.             <img src="https://..."/>
  5.           </a>
  6.     </li>
  7. </ul>
But if I do a manuel page chachge by clicken in the menubar the selection is correct.

So can you please help me, and reveal the trick to me?

best regards,
angelo hannes