运行结果都显示失败
<!DOCTYPE html>
<html>
<head>
<title> new document </title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<script type="text/javascript">
function openwindow(){
var choose=confirm("是否打开?");
if(choose==true){
var aaa=prompt("确认打开网址","http://www.imooc.com");
if(aaa==true){
window.open(aaa,'_blank','width=400,height=500,menubar=no,toolbar=no');
}
else{
alert("失败");
}
}
else{
alert("失败");
}
}
}
</script>
</head>
<body>
<input type="button" value="新窗口打开网站" onclick="openwindow()" />
</body>
</html>