how to access variables on same page in php
<p>I want to access variable on same page but I can't .. my code is given below but the errors occurs Undefined index: cars</p>

<pre><code>&lt;form name="form1" action="#" method="post"&gt;
&lt;select onChange="openOffersDialog(this.value);" name="cars" id="cars"&gt;  
  &lt;option value="Volvo" id="Volvo"&gt;Volvo&lt;/option&gt;        
  &lt;option id="Saab" value="Saab" selected&gt;Audi&lt;/option&gt;                  
&lt;/select&gt;
&lt;/form&gt;
&lt;?php $car = $_GET['cars'];
    switch ($car) { 
    case "Volvo": 
    echo  "&lt;table width='50%' border='0'&gt;
          &lt;tr&gt;
            &lt;td&gt;Volvo1&lt;/td&gt;
            &lt;td&gt;Volvo2&lt;/td&gt;
          &lt;/tr&gt;      
        &lt;/table&gt;"; 
    break; 
    case "Saab": 
    echo  "&lt;table width='50%' border='0'&gt;
          &lt;tr&gt;
            &lt;td&gt;Saab1&lt;/td&gt;
            &lt;td&gt;Saab2&lt;/td&gt;
          &lt;/tr&gt;      
        &lt;/table&gt;" ;
    break;
    default: 
    echo "Sorry,&lt;br&gt;";  
    } ?&gt;
</code></pre>
