views:

198

answers:

1

With the latest jqModal release (+r14), I'm having an issue with the new feature of live links. Whenever the live-loaded trigger link is clicked on, it redirects to the HREF instead of loading it via AJAX. How can I make it behave normally?

I've searched around and other people seem to have this issue, but it's gone unresolved.

$('a.modal-product-trigger').live('click', function(){
 $('#modal-product').jqmShow(this);
});
+1  A: 

I'm not particularly familiar with jqModal, but try canceling the event:

$('a.modal-product-trigger').live('click', function(){
        $('#modal-product').jqmShow(this);
        return false;   
});

If you don't do this the event will go through with its default action, which is to act as a regular link.

Paolo Bergantino
Perfect — thanks for your help. It works great now. I appreciate it.
James Skidmore