利用js跳转页面
利用 js
跳转页面,其实也就是利用window对象中href
属性进行跳转
第一种方法,延时跳转
function me(){
window.location.href = "next.html";
}
setTimeout(me,3000);
第二种方法,利用iframe框架
document.writeln("<iframe scrolling='no' frameborder='0' marginheight='0' marginwidth='0' width='100%' height='5000' allowTransparency src=next.html></iframe>");
第三种跳转方式,在新窗口中打开页面
window.open('next.html');
返回上一个页面
window.history.back(-1);