Thanks so much Richard, that's exactly what I was looking for! - Sean
-- http://catalyticat.com 2008/6/13 Richard D. Worth <[EMAIL PROTECTED]>: > $('.child').click(function(e) { > e.stopPropagation(); > }); > > This will prevent the click event from bubbling up to the parent element, > while still allowing the link to be followed (unlike return false). See > > http://developer.mozilla.org/en/docs/DOM:event.stopPropagation > > - Richard > > Richard D. Worth > http://rdworth.org/ > > > On Fri, Jun 13, 2008 at 6:59 AM, testpilot <[EMAIL PROTECTED]> > wrote: > >> >> >> Hi, >> I hope this is a simple problem but I can't seem to find an answer. >> I have something like the following: >> >> <script> >> $('.parent').toggle(function() { >> $(this).slideUp(); >> }, function() { >> $(this).slideDown(); >> }); >> </script> >> >> <div class="parent" style="background:#000;"> >> <div class="child"> >> <'a href="#">link<'/a> >> </div> >> </div> >> >> Where the 'parent' div triggers a function on click/toggle but I want to >> keep the default behaviour of the link inside the child element (ignoring >> the extra ' ). >> >> Is there any way to do this? Something like $('.child').unbind(function); >> ? >> Or trigger the href attribute onclick instead of the slideUp? >> >> Any help would be greatly appreciated! >> -- >> View this message in context: >> http://www.nabble.com/How-to-un-inherit-a-function-of-a-parent-element--tp17819990s27240p17819990.html >> Sent from the jQuery General Discussion mailing list archive at >> Nabble.com. >> >> >