IE7 preventDefault() not working on skip links
I currently have skip links that jump to the div id's and was using e.preventDefault() to stop the url from changing when jumping to the element but in IE7 or IE8 it doesn't work at all using e.preventDefault() and if I take it out the url changes to the div the anchor tag contains reference to. Is their any fix or way around this?
Here is the code
$('body').delegate('a.skiplink-accessible-text', 'click', function (e) {
//e.preventDefault();
if(!$.browser.msie){
e.preventDefault();
}
var jumpTo = $(this).attr('href');
$('body').find(jumpTo).attr('tabindex',-1).focus();
});