码迷,mamicode.com
首页 > Web开发 > 详细

js弹出提示框并跳转页面

时间:2014-07-10 10:15:35      阅读:248      评论:0      收藏:0      [点我收藏+]

标签:http   java   art   io   javascript   type   

1。提示框有两个选择项,点确定跳转,取消停留在原页面
ScriptManager.RegisterStartupScript(Page, this.GetType(), "", "<script>if(confirm(‘请登录
?‘)){location.href=‘login.aspx‘};</script>", false);

2.提示框只有一个确定按钮,跳转到指定页面
ScriptManager.RegisterStartupScript(page, this.GetType(), "", "<script>alert(‘请登录?‘);location.href=‘login.aspx‘</script>", false);

 

或者是:

 

<script language="JavaScript">

 

alert(‘提示信息‘);-------------------------提示框内容

location.href=‘https://125.69.90.54/‘;-----------------------点击按钮后跳转页面url

document.onmousedown=click

</script>

js弹出提示框并跳转页面,布布扣,bubuko.com

js弹出提示框并跳转页面

标签:http   java   art   io   javascript   type   

原文地址:http://www.cnblogs.com/smy520/p/3812205.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!