This is my jQuery code:
$('.ajax_modal a').not('.popup').live('click', function(e){
//do something
});
When I click on the anchor a.popup, I would expect nothing to happen:
<div class="ajax_modal">
<a class="popup">Should do nothing</div>
<a class="something">Should do something<a>
</div>
Instead I get the following error which is breaking my page:
Error: Syntax error, unrecognized expression: .ajax_modal a.not(.popup)
.live()doesn’t work well with chained traversal methods.Change that to