safari 浏览器下,confirm()方法弹出框,好和取消 无法点击。
代码如下:
if(window.confirm("未登录,请先登录!"))
{
...页面跳转...
}
真是奇怪了!
------解决方案--------------------------------------------------------
safari 5.0.3下面测试ok啊
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=gb2312">
<title> new document </title>
<meta name="keywords" content="">
<meta name="description" content="">
</head>
<body>
<script type="text/javascript">
<!--
if(window.confirm("未登录,请先登录!"))
{
alert("confirm yes")
}
else{alert("confirm no")}
//-->
</script>
</body>
</html>