js跳转页面与打开新窗口的方法
1.超链接<a href="https://blog.csdn.net/wang20y8" title="打开一个新页面" ">同当前窗口中打开窗口</a>
等效于js代码
window.location.href="https://blog.csdn.net/wang20y8"; //在同当前窗口中打开窗口
window.top.location.href="https://blog.csdn.net/wang20y8"; //在同当前窗口中打开窗口
2.超链接<a href="https://blog.csdn.net/wang20y8" title="打开一个新页面" target="_blank">弹出新页面打开</a>
等效于js代码
window.open("https://blog.csdn.net/wang20y8"); //在另外新建窗口中打开窗口
controller:
HttpServletResp