<html><head><title>用函数控制窗口</title>
<SCRIPT LANGUAGE="javascript">
<!--
function openwin(){
window.open("http://www.google.com","newWidow","height=50,winth=50,top=0,left=0,toolbar=no,menubar=no,scrollbars=no,resizable=yes,location=no,status=no");//写成一行
}
-->
</sript>
</head><body>
<a href="http://www.baidu.com" onclick="openwin()">open</a>
</body></html>
大家帮我看看这个程序那个地方有错误啊!
<SCRIPT LANGUAGE="javascript">
<!--
function openwin(){
window.open("http://www.google.com","newWidow","height=50,winth=50,top=0,left=0,toolbar=no,menubar=no,scrollbars=no,resizable=yes,location=no,status=no");//写成一行
}
-->
</sript>
</head><body>
<a href="http://www.baidu.com" onclick="openwin()">open</a>
</body></html>
大家帮我看看这个程序那个地方有错误啊!
改成
</script>
即可
<!--
function openwin(){
window.open("http://www.google.com","newWidow","height=50,winth=50,top=0,left=0,toolbar=no,menubar=no,scrollbars=no,resizable=yes,location=no,status=no"); //写成一行}
-->
</script>
<a href="http://www.baidu.com" onclick="openwin()">open</a>
点一下它打开两个页面:baidu页和google页。