title: How to display a dropdown select based on the value of other dropdown select?
body: <p>Suppose I have a dropdown select option like below:</p>
  
  <pre><code> &lt;form&gt;
      &lt;select name="option" &gt;
                  &lt;option value=""&gt;Select a Value:&lt;/option&gt;
                  &lt;option value="1"&gt;Option 1&lt;/option&gt;
                  &lt;option value="2"&gt;Option 2&lt;/option&gt;
  
      &lt;/select&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>When any user Selects the Option 1 I want to display the following dropdown select beside it instantly</p>
  
  <pre><code> &lt;select name="name" &gt;
                  &lt;option value=""&gt;Select a person:&lt;/option&gt;
                  &lt;option value="john"&gt;john&lt;/option&gt;
                  &lt;option value="Micheal"&gt;Micheal&lt;/option&gt;
  
      &lt;/select&gt;
  </code></pre>
  
  <p>Or, if any user Selects the Option 2 I want to display the following dropdown select beside it instantly</p>
  
  <pre><code> &lt;select name="class" &gt;
                  &lt;option value=""&gt;Select a person:&lt;/option&gt;
                  &lt;option value="Class 1"&gt;Class 1&lt;/option&gt;
                  &lt;option value="Class 2"&gt;Class 2&lt;/option&gt;
  
      &lt;/select&gt;
  </code></pre>
  
  <p>Would you please kindly show me how to do this?
  I am using Codeigniter.</p>