jquery 跳转到其他页面

第一步引入jquery

<script src="http://code.jquery.com/jquery-2.1.4.min.js"></script>
 
第二步(也是最关键一步)
$(location).attr('href','1.html')//在需要跳转的地方放入
 
返回上一页面
history.back();

猜你喜欢

转载自www.cnblogs.com/mcll/p/11840265.html