I’m currently taking over any links on the page that begin with “users”:
$('a[href^="/users/"]').live('click', function(event) {
…however, this is a little greedy. I want to exclude any links to “stuff” that are NOT with the “versions” class. I tried:
$('a[href^="/users/"]').not('div.versions a').live('click', function(event) {
…but this breaks the whole block. My next guess it is breaking because of “live” — with the way events trickle up.
Any ideas? Is there a better way to do this?
try merging
notin the main selector:Check here as well: .not() with .live() not working, seems to be the same problem.