最赞回答 / Caballarii
var mychar=confirm("是否打开新窗口?");后面的}位置错了,要挪到最后面http://www.imooc.com/用了中文的冒号 <...code...>
2015-12-28
function openWindow(){
var myCon = confirm();
if(confirm = 1)
{
var Adr = prompt("确定打开的网站","http://www.imooc.com");
window.open(Adr,'_test','meanbar = no,toolba=no,width = 400,hight = 500);
}
}
var myCon = confirm();
if(confirm = 1)
{
var Adr = prompt("确定打开的网站","http://www.imooc.com");
window.open(Adr,'_test','meanbar = no,toolba=no,width = 400,hight = 500);
}
}
最新回答 / 不亦说乎
<meta http-equiv="Content-Type" content="text/html; charset=gbk"/> 把“charset=gbk"改成”charset=utf-8"
2015-12-28
最新回答 / ayundan
修改后:<!DOCTYPE html><html> <head> <title> new document </title> <meta http-equiv="Content-Type" content="text/html; charset=gbk"/> <script type="text/javascript"> function openWindow() { var message=...
2015-12-28
已采纳回答 / js_saber
var url = prompt("请输入要打开的网址:","http://www.imooc.com/");里面地址中http后面冒号是中文,改成英文就可以了
2015-12-26