var myage=alert(111)
if(myage==true){document.write(111)}
else(document.write(2123))
if(myage==true){document.write(111)}
else(document.write(2123))
2021-05-22
function openWindow(){
var conf=confirm("是否打開");
if(conf==true)
{
var newurl=prompt("請輸入網址","http://www.xianlaiwan.cn/");
var mywin=window.open(newurl,'_blank','width=400,height=500');
}else{
alert("Follow your order!");
}
}
var conf=confirm("是否打開");
if(conf==true)
{
var newurl=prompt("請輸入網址","http://www.xianlaiwan.cn/");
var mywin=window.open(newurl,'_blank','width=400,height=500');
}else{
alert("Follow your order!");
}
}
function openWindow()
{
var conf = confirm("Do you sure open the new windows?");
if (conf)
{
var newwin = prompt("Please Input Url","http://www.xianlaiwan.cn/");
var mywin = window.open(newwin);
}
else
{
alert("Follow your order!");
}
}
{
var conf = confirm("Do you sure open the new windows?");
if (conf)
{
var newwin = prompt("Please Input Url","http://www.xianlaiwan.cn/");
var mywin = window.open(newwin);
}
else
{
alert("Follow your order!");
}
}
<script type="text/javascript">
function Wopen(){
window.open('http://www.xianlaiwan.cn','_blank','width=600,height=400,top=100,left=0')
}
</script>
function Wopen(){
window.open('http://www.xianlaiwan.cn','_blank','width=600,height=400,top=100,left=0')
}
</script>
2021-01-21
document.write("hello");
document.getElementById("p1").style.color="blue";
document.getElementById("p1").style.color="blue";
2021-01-21
function openWindow(){
var open=confirm("是否打開新的窗口?")
if(open==true)
{var t =prompt("請輸入網址")
if(t='http://www.xianlaiwan.cn')
{window.open(t,'test','width=400,height=500,menubar=no,toolbar=no') }
else{document.write("請輸入正確的網址")}}
else{document.write("ok")}}
var open=confirm("是否打開新的窗口?")
if(open==true)
{var t =prompt("請輸入網址")
if(t='http://www.xianlaiwan.cn')
{window.open(t,'test','width=400,height=500,menubar=no,toolbar=no') }
else{document.write("請輸入正確的網址")}}
else{document.write("ok")}}