我正在尝试将href加载到特定维度的弹出窗口中,这些窗口也在屏幕中心.
这是我的来源:@H_502_3@
<li> <a class="sprite_stumbleupon" href="http://www.stumbleupon.com/submit?url=http://www.your_web_page_url" target="_blank" onclick="return windowpop(545,433)"></a> </li>
这里是我的javascript:@H_502_3@
function windowpop(url,width,height) { var leftPosition,topPosition; //Allow for borders. leftPosition = (window.screen.width / 2) - ((width / 2) + 10); //Allow for title and status bars. topPosition = (window.screen.height / 2) - ((height / 2) + 50); //Open the window. window.open(url,"Window2","status=no,height=" + height + ",width=" + width + ",resizable=yes,left=" + leftPosition + ",top=" + topPosition + ",screenX=" + leftPosition + ",screenY=" + topPosition + ",toolbar=no,menubar=no,scrollbars=no,location=no,directories=no"); }
测试时似乎返回404错误.我究竟做错了什么?@H_502_3@
感谢堆@H_502_3@