PHP - How to return a variable from a class method?
<p>I don't understand the concept of getter and setter methods in PHP, pls help me out.</p>

<p>Let's say I have this class:     </p>

<pre><code>class something()
{
  public function test()
  {
    $bla = 10;
    return $var;
  }
}
</code></pre>

<p>How do I get the follwing code to work:</p>

<pre><code>    $something-&gt;test();
    echo $bla;
</code></pre>

<p>Thanks!</p>
