Javascript Show hide variable for form
<p>Here is the code I am having trouble with everyone. This is what I have been working on for 8 hours since I do not know js. I got most of this from the w3school.com site and just have been trying to piece everything together. ugh please help</p>

<pre><code>&lt;script type="text/javascript"&gt;
var stringToMatch = 'christopher',  
input = document.getElementById('text'),  
div = document.getElementById('divColor1');  

 function toggle (switchElement){  
 if (this.value == stringToMatch){  
    div.style.display = 'block';  
}  
else {  
    div.style.display = 'none';  
}  
};?  
 &lt;/script&gt;


 &lt;!--This is the start of the code which i want to appear--&gt; 
 &lt;h3&gt;Coupon Redeem&lt;/h3&gt; 
 &lt;form action="test" method="post"&gt; 
Please type in the Coupon Code you have recieved: 
 &lt;form id='coupon' onChange="javascript: ShowMenu(document.getElementById('text').value,'divColor1');"&gt;  
&lt;input id="text" type="text"&gt; 
&lt;input type="button" id="text" value="Redeem" onClick="toggle(this)" /&gt; 
&lt;/form&gt;
 &lt;!--This is the start of the hidden field that i want to appear when the coupon code is entered     correctly--&gt; 
&lt;div id="divColor1" style="display:none;"&gt; 
&lt;form action="https://www.paypal.com/cgi-bin/webscr" method="post"&gt; 
&lt;input type="hidden" name="cmd" value="_s-xclick"&gt; 
&lt;input type="hidden" name="hosted_button_id" value="asjsanxci"&gt; 

  &lt;input type="hidden" name="on0" value="Tokens"&gt;Tokens 
    &lt;select name="os0"&gt; 
  &lt;o ption value="5 tokens"&gt;5 tokens$5.00 USD&lt;/option&gt; 
 &lt;option value="10 tokens"&gt;10 tokens$10.00 USD&lt;/option&gt; 
 &lt;option value="15 tokens"&gt;15 tokens$13.00 USD&lt;/option&gt; 
 &lt;option value="20 tokens"&gt;20 tokens$18.00 USD&lt;/option&gt; 
 &lt;option value="25 tokens"&gt;25 tokens$23.00 USD&lt;/option&gt; 
 &lt;option value="30 tokens"&gt;30 tokens$27.00 USD&lt;/option&gt; 
 &lt;option value="35 tokens"&gt;35 tokens$33.00 USD&lt;/option&gt; 
 &lt;option value="40 tokens"&gt;40 tokens$38.00 USD&lt;/option&gt; 
  &lt;option value="50 tokens"&gt;50 tokens$45.00 USD&lt;/option&gt; 
 &lt;/select&gt;  
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&lt;input type="hidden" name="on1" value="Username Verification"&gt;Username Verification 
 &lt;input type="text" name="os1" maxlength="200"&gt; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&lt;input type="hidden" name="currency_code" value="USD"&gt; 
&lt;input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynow_SM.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!"&gt; 
&lt;/form&gt; 
&lt;/div&gt; 

&lt;br&gt; 
&lt;/form&gt; 
</code></pre>
