title: Global Variables in a WordPress Plugin
body: <p>I am trying to create my first WordPress plugin. Even in trying to create the install function, things are being a pain.</p>
  <p>I want to set some <code>global variables</code> specific to my plugin rather than putting the literal values throughout the various functions. However, my install function does not pick up these <code>global variables</code>.</p>
  <p>Here is my code so far:</p>
  <pre><code>$version = '1.0a';
  register_activation_hook( __FILE__, 'install' );
  function install() {
    global $version;
    add_option( 'test_version', $version );
  }
  </code></pre>
  <p>Obviously this is pretty straight forward on my end. Any ideas what is going wrong here??</p>