使用function方法可以创建对象,这时this代表当前构造的对象
function test {
   this.word = "this is a test";
}
ice_berg16 = new test;
alert(ice_berg16.word);

解决方案 »

  1.   

    this 代表当前对象,也就是你写的对象, ice_berg16(寻梦的稻草人) 的解释已经很好了
      

  2.   

    function test {
       this.word = "this is a test";
    }function 表示创建一个test类
    this表示创建一个这个类
    this.word表示创建一个word属性
      

  3.   

    this表示的指向第一个使用this的function,这个function表示为一个class,
    在其它函数的this也表示指向class中的属性.
      

  4.   

    看看这文章http://www.xs4all.nl/~ppk/js/this.html
      

  5.   

    wanghr100(灰豆宝宝.net) 
    推荐的这个文章看起来是最详细的
    不过看不太懂E文
    哪位大哥麻烦您翻译一下?