它转到未定义,然后转到 test.com。
我怎样才能让它去http://url.com然后http://test.com 然后http://anotherdesiredurl.com
<head>
<script type="text/javascript">
<!--
function popup(url) {
var width = 300;
var height = 200;
var left = (screen.width - width) / 2;
var top = (screen.height - height) / 2;
var params = 'width=' + width + ', height=' + height;
params += ', top=' + top + ', left=' + left;
params += ', directories=no';
params += ', location=no';
params += ', menubar=no';
params += ', resizable=no';
params += ', scrollbars=no';
params += ', status=no';
params += ', toolbar=no';
newwin = window.open(url, 'popup', 'params');
if (window.focus) {
newwin.focus()
}
return false;
}
setTimeout(function() {popup('http://www.test.com/'); }, 8000)
//-->
//]]>
</script>
<head>
<body>
<input type="button" value="Click Blitch" onclick="popup();"/>
</body>