i have a link with a click handler here. the href is filled with information i need. but i dont want the click to open this link. so i did event.preventDefault and it works fine. But i need to target=”_top” ich someone clicks the link. is this even possible?
Share
changed the
event.preventDefault();function toreturn false;and did a html animatation with scrollTop:$('html, body').animate({scrollTop:0});now the link is not following the href but it scrolls to top