不知道怎么解释。
this就是“这个”的意思。 
但是function point(x,y)和function pointExtend(x,y,z)
没有任何关系(子女关系),
比如说父亲和子女,子女可以设置父亲的属性。父亲设置的属性子女可以取得。而这样,就有一堆娃儿的关系了:
function pointExtend(x,y,z){
this.point(x,y);
}
pointExtend.prototype.point = function(x,y){
this.x = "s";
this.y = "ww";
}
//测试实例
var pe = new pointExtend(1,2,3);
alert(pe.x);
alert(pe.y);

解决方案 »

  1.   

    point(x,y);//---------------错
    应该是类似于这样的吧
    point.apply(this,[x,y]);
      

  2.   

    wllllll 和 yonghengdexingxing 两位帅哥说的都对,可是也没有解释我的问题啊,呵呵
      

  3.   

    //++++++是我添加的注释
    <html xmlns="http://www.w3.org/1999/xhtml"> 
    <head> 
        <title>继承 </title> 
    </head> 
    <body> 
    <script type="text/javascript"> 
    function point(x,y){ 
    this.x = "s"; 
    this.y = "ww";
    alert(this==window);  //++++++这里将返回true,可见你直接调用point(x,y)时,this不是你想要的那个object
    }function pointExtend(x,y,z){  //this.point = point; 
    //this.point(x,y); 
    //delete this.point;  point(x,y);//---------------错  //-----------------------------???????????为什么不直接用point(x,y) 
    //何必向上面这么复杂呢,但是我试了一下,却不好使????????????????、 

    //我在网上的说这句话的解释是: 
    //这样写表面看起来是正确的,其实是错误的。因为只有new出来的对象才有this,所以调用point里的this就没有值了 
    //---------听不懂 

          
    //测试实例 
    var pe = new pointExtend(1,2,3); 
    alert(pe.x); 
    alert(x);   //++++++x和y最后加到window对象了
    alert(pe.y); //++++++x和y最后加到window对象了
    alert(y);
          
    </script> </body> 
    </html>
      

  4.   

            //this.point = point;
            //this.point(x,y);
            //delete this.point; 這是在ECMAScript出call和apply之前的類抄寫方式!功能就相當于現在的call和apply;