search

Home  >  Q&A  >  body text

window.open("www.baidu.com","_blank","width=600,height=400");为什么没有效果啊?

function open(){
 var a=confirm("欢迎");
 if(a==true)
 {
   window.open("www.baidu.com","_blank","width=600,height=400");
 }
    
}


phpcn_u224phpcn_u2242900 days ago1306

reply all(2)I'll reply

  • 数据分析师

    数据分析师2017-09-30 22:52:00

    window.open("www.baidu.com","_blank","width=600,height=400");Why doesn't it work? -PHP Chinese website Q&A- window.open("www.baidu.com","_blank","width=600,height=400");Why doesn't it work? -PHP Chinese website Q&A

    Please watch and learn.

    reply
    0
  • 阿神

    阿神2016-12-19 09:38:49

    把"www.baidu.com"改成"http://www.baidu.com"试试,你的链接地址没有加http协议。

    reply
    1
  • Cancelreply