更新时间:2023-09-03 10:27:58
您可以将click事件附加到链接,并使浏览器的默认行为为空.
You can attach a click event to a link and null the browser's default behaviour.
<a href="http://example.com">Example</a>
$('a').click(function(event) {
event.preventDefault();
func();
});