jquery如何實現點擊圖片后跳轉到另外一個頁面?
$("#pic").click(function(){ location.href='newpage.html';});
上面的相當于<a href="newpage.html" target="_self"><img src="img.jpg" /></a>$("#pic").click(function(){ window.open('newpage.html');});
相當于<a href="newpage.html" target="_blank"><img src="img.jpg" /></a>