+ -
当前位置:首页 → 问答吧 → JS脚本遇到“尚未实现”错误

JS脚本遇到“尚未实现”错误

时间:2011-11-08

来源:互联网

在google搜索了下,要求如下改:
再写一个函数,譬如function loadFunc(){ myFunc(var1,var2) },然后window.onload = loadFunc;
使用匿名函数。onload =function(){myFunc(var1,var2)}

请高手帮忙改下,我不懂js。请问下面的这里的onload要怎么改?是TINY.box里的一段代码,谢谢了。

JScript code
        fill:function(c,u,k,a,w,h){
            if(u){
                if(v.image){
                    var i=new Image(); i.onload=function(){w=w||i.width; h=h||i.height; TINY.box.psh(i,a,w,h)}; i.src=v.image
                }else if(v.iframe){
                    this.psh('<iframe src="'+v.iframe+'" width="'+v.width+'" frameborder="0" height="'+v.height+'"></iframe>',a,w,h)
                }else{
                    var x=window.XMLHttpRequest?new XMLHttpRequest():new ActiveXObject('Microsoft.XMLHTTP');
                    x.onreadystatechange=function(){
                        if(x.readyState==4&&x.status==200){p.style.backgroundImage=''; TINY.box.psh(x.responseText,a,w,h)}
                    };
                    if(k){
                        x.open('POST',c,true); x.setRequestHeader('Content-type','application/x-www-form-urlencoded'); x.send(k)
                    }else{
                            x.open('GET',c,true); x.send(null)
                    }
                }
            }else{
                this.psh(c,a,w,h)
            }
        },

作者: zugoucom   发布时间: 2011-11-08

不知道你要做什么 具体代码

作者: qq283868910   发布时间: 2011-11-08

onload 你要改成什么样的 ?要做些什么 。

作者: zell419   发布时间: 2011-11-08