I have seen similar quesitons answered on the website, but I can't find a fix that works for me :(
I am trying to use jQuery's live() method to trigger an event several time in a page's division after it's content is refreshed, when clicking on a link within the division itself.
The content is first loaded in "divdroite" after a click on a link within "divgauche", and then I'd like clicks within "divdroite" to refresh its own content any number of times.
The code is as follows :
$j("body").on('click', "#divgauche a", function (event1) {
    $j("#divdroite").load((this.href + " #courscontainer"), function () {
        $j('#divdroite .collapsible').on('click', function (g) {
            $j('>*:has(*)', g.target).slideToggle(300);
            g.preventDefault();
            g.stopPropagation();
        });
    });
    event1.preventDefault();
    event1.stopPropagation();
});
$j("#divdroite a").live('click', function (event2) {
    $j("#divdroite").load((this.href + " #courscontainer"), function () {
        $j('#divdroite .collapsible').on('click', function (h) {
            $j('>*:has(*)', h.target).slideToggle(300);
            h.preventDefault();
            h.stopPropagation();
        });
    });
    event2.preventDefault();
    event2.stopPropagation();
});
Any help would be greately appreciated.
Thanks!!
 
     
     
    