variable assignment inside 'IF' condition
<p>in php, something like this is fine:</p>

<pre><code>&lt;?php
    if ( !$my_epic_variable = my_epic_function() ){
        // my epic function returned false
        // my epic variable is false
        die( "false" );
    }

    echo $my_epic_variable;
?&gt;
</code></pre>

<p>I suppose is a shorter way of doing:</p>

<pre><code>$my_epic_variable = my_epic_function();
if ( !$my_epic_variable ){
        die( "false" );
}
</code></pre>

<p>Can this be done is javascript? I've tried to no success, wasnt sure if there was some kind of special syntax or something</p>
