I've build a site that has accordion sections that expand whenever someone clicks on the header section for that page, the click handler is placed on
$('.section h2').click
However, when a user is logged in as admin, there are 'EDIT' links applied to the header, so I only want the section to expand if the area clicked is not "a.edit-link".
I've tried things like $('.section h2:not(a.edit-link)').click
... or $('.section h2').not('a.edit-link').click
, but niether of these options are working for me..
Am I missing out on something obvious?