title: Global variable initialization issue
body: <p>I've a Drupal file (mymodule.module) which contains something like(actual code is very long):</p>
  
  <pre><code>$test =1;
  
  //hook_user_login
  function mymodule_user_login()
  {
  global $test;
  print "$test";
  }
  </code></pre>
  
  <p>But when this hook function "mymodule_user_login" is called by Drupal on user login  --  $test's value is found to be null.</p>
  
  <p>What could be the reason?</p>
  
  <p>I've tried Googling but could not find useful answer.</p>