title: Displaying a textbox depending on selection from the select box
body: <p>I have an application in which the user needs to enter Industry while filling out a form. We have several pre-made choices in the drop down box, but he also needs to enter manually. He can click on Other, and a input box should be displayed asking for the manual entry.</p>
  
  <p>I have written this javascript codes which solves my purpose, but when the page loads..I can see the box there even when the user hasn't selected anything. 
  How can I fix this, so this only shows a checkbox when the user clicks Other, or removes the checkbox if the user clicks on another option after hitting Other once.</p>
  
  <p>HTML code :p</p>
  
  <pre><code>&lt;tr&gt;
      &lt;td&gt;Industry*&lt;/td&gt;
      &lt;td&gt;
          &lt;select name="industry" id="industry" class="validate[required]" onchange="javascript: test()"&gt; 
              &lt;option value="BPO"&gt;BPO&lt;/option&gt;
              &lt;option value="Call Centre"&gt; Call Centre &lt;/option&gt;
              &lt;option value="Software"&gt;Software&lt;/option&gt;
              &lt;option value="Networking"&gt;Networking&lt;/option&gt;
              &lt;option value="Management"&gt;Management&lt;/option&gt;
              &lt;option value="Other"&gt;Other&lt;/option&gt;
          &lt;/select&gt;
      &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr&gt;
      &lt;td&gt;&lt;/td&gt;
      &lt;td&gt;
          &lt;input type="text" name="industryo" id="industryo" placeholder="Enter Manually"&gt;
      &lt;/td&gt;
  &lt;/tr&gt;
  </code></pre>
  
  <p>JS</p>
  
  <pre><code>&lt;script&gt;
  function test()
  {
    //alert("something");
    var industry = document.getElementById('industry').value;
    if(industry == "Other")
    {
      $( document ).ready(function() {
        // Handler for .ready() called.
        $('#industryo').show();
      });
    }
    else
    {
      $( document ).ready(function() {
        $('#industryo').hide();
      });
    }
  }
  &lt;/script&gt;
  </code></pre>
  
  <p>Any suggestion is helpful.</p>