当前位置: 代码迷 >> JavaScript >> 为什么不能弹出窗口?该怎么处理
  详细解决方案

为什么不能弹出窗口?该怎么处理

热度:153   发布时间:2012-03-07 09:13:51.0
为什么不能弹出窗口?
function edit(){
var mystr="left:(document.body.scrollWidth-250)/2,top:(document.body.scrollHeight-125)/2, width:250, height:125,url: "folk.aspx"";
var edit = new Window("edit", {"+mystr+"});
}
为什么不能弹出窗口,而用
function edit(){
var edit =new Window("edit", {left:(document.body.scrollWidth-250)/2,top:(document.body.scrollHeight-125)/2, width:250, height:125,url: "folk.aspx"});}
则可以,谢谢各位大哥


------解决方案--------------------
偶不会那样的语法。只会window.open,而且测试你那个代码也不行,你那段代码要在.net运行才行的?
------解决方案--------------------
看不懂
------解决方案--------------------
function edit(){ 
var mystr="{left:(document.body.scrollWidth-250)/2,top:(document.body.scrollHeight-125)/2, width:250, height:125,url: "folk.aspx"}"; 
var edit = new Window("edit", mystr); 
}
  相关解决方案