tags:

views:

17

answers:

1

I have the following function that loads "mypage.htm" into "#flowplayer-content".

This works

 $('.small-images a').bind("click", function(event) {

    var uri = "mypage.htm";
    $("#flowplayer-content").load(uri, null, function(responseText, textStatus, XMLHttpRequest) {

    });
    event.preventDefault();
});

"mypage.htm" contains ahref. I want to call this event.

$("a").live("click", function() {
    alert("handler hit");
});

but i can't seem to hit it

A: 

When do you call the live method? This should be called before the new HTML is loaded.

Also, the way you are doing it now affects all links, even the one that loads the html. Am I right to guess that you are using a different selector in the real thing?

Perhaps, it will be better to post the full source (javascript + html).

kgiannakakis