using include_once causes undefined variable notice
<p>I have a file named "config.php" which contains a variable named <code>$unit_names</code>. In a class I have the following method which returns unit name by it's id. I use this method for all rows in a table, but the problem is <code>config.php</code> is included only in the first call to the method. next calls cause the notice: <code>undefined variable $unit_names...</code></p>

<p>If I replace <code>include_once</code> by <code>include</code> the notice disappears. But why? <code>include_once</code> should load the <code>config.php</code> file.</p>

<pre><code>public function get_unit_name($unit_id) 
    {   
            include_once("config.php");
            return $unit_names[$unit_id];
    }   
</code></pre>
