why does if(function_name()) not work?
<p>Hey guys really quick question, I have a simple test that I was doing to prove a point and it does not work like I expected but I am not sure why it does not work.</p>

<pre><code>function test(){
    echo 'test';
}

if (test()){
    echo 'ok';
}
</code></pre>

<p>That was my test. 'ok' is not echoed and I am not sure why. I was testing this because my real code is calling a class method and is also not working.</p>

<pre><code>if($database-&gt;addNewUser($user, md5($pass), $userfile, $email, $age)){
    return 0;  //New user added succesfully
}
</code></pre>

<p>The method addNewUser executes and does what it should, but the return 0; does not. Anyone have any insight into this?</p>
