$('#grabMe') will search the document for an element with ID "grabMe"

Have you added grabMe to the document?


On Jan 13, 6:00 pm, CrustyDOD <anze.stok...@gmail.com> wrote:
> Hey!
>
> I've created one div with FlyDOM plugin which uses createElement
> function to add stuff to DOM. Now the problem is that once i add the
> element, i cannot access it in anyway.
>
> For example with FlyDOM plugin i create:
> <div id="grabMe">It works!</div>
>
> After the JS for creating element i have this:
> $('#grabMe').click(function() {
>     alert($(this).html());
>
> });
>
> It doesn't work.
>
> There are no errors shown in Firebug, the element is in DOM, id is
> set. It's all there.
>
> Am i missing something here? I'm confused :S
>
> Using jquery 1.2.6

Reply via email to