title: How can i access Return value throught the construct() from another function In PHP?
body: <p>I'm trying to access the return value of the <code>test()</code> inside <code>__constructor()</code> but I stucked it. anyone Can tell me about that how can I get the return value from <code>__constructor()</code>. I appreciate your answer!
      
  
  <pre><code>class some
  {
      public function __construct()
      {
          $this-&gt;test(); // I want this test()
      }
  
      public function test() 
      {
          return 'abc';
      }
  }
  
  $some = new some;
  
  
  echo $some;
  
  print_r($some);
  </code></pre>
  
  <p>I tried by myself, but nothing happens!</p>
  
  <p>Thanks!</p>