title: Function call from within function, variable scope
body: <p>I just want to confirm that the following will NOT work:</p>
  
  <pre><code>function f1(){
    $test = 'hello';
    f2();
  }
  
  function f2(){
    global $test;
    echo $test;
  }
  
  f1(); //expected result 'hello'
  </code></pre>
  
  <p><a href="http://php.net/manual/en/language.variables.scope.php" rel="nofollow">http://php.net/manual/en/language.variables.scope.php</a></p>
  
  <p>Is there no way to just "flow" up the scope chain like you can do in Javascript?  From the manual, it seems that my option for this is global or nothing at all.</p>
  
  <p>I just wanted to know if that was correct.</p>