title: Javascript OOP initialization and method call issue
body: <p>I have a javascript class <code>person</code>, I have made Obj of it, works fine. But I need to access the function from <code>person</code> class.</p>
  
  <p>When I tried to access I get <code>..not a function error</code>.</p>
  
  <p>Please help!</p>
  
  <p>Important... I need to initialize the 'person' class, and call the method exactly same way of my code. How??  Help!</p>
  
  <p>Here is my code:</p>
  
  <pre><code> var person = {
     setBasic: function(data) {
       alert(data.name + ' ' + data.age);
     },
     this:getPerson = function() {
       alert('get me');
     },
     success: null
   };
  
   //lets instantiate.enter code here
  
   var perObj = new person.setBasic({ 'name': 'ikair', 'age': 33, });
  
   // works fine..
  
   //now I need to call a function of person class:
  
   perObj.getPerson();
  
   //not working :(... how to call function with prev code?
  </code></pre>