title: Can I use logical OR || in PHP variable declaractions?
body: <p>This code works:</p>
  
  <pre><code>$foo = getFoo();
  if (!$foo) $foo = getBar();
  if (!$foo) $foo = getJiggy();
  if (!$foo) $foo = getWithIt();
  </code></pre>
  
  <p>I thought I'd seen somewhere a simplification of it with logical operators:</p>
  
  <pre><code>$foo = (getFoo() || getBar() || getJiggy() || ...);
  </code></pre>
  
  <p>I figured that the first true statement would get passed, but instead, it's just setting $foo to boolean <code>true</code> instead of the return value of <code>getFoo()</code>, <code>getBar()</code>, etc. </p>
  
  <p>Is there a simplification like what I'm thinking of?</p>