title: jQuery filter select options
body: <p>Is it possible to filter specific select options? </p>
  
  <p>I have a code :</p>
  
  <pre><code>&lt;select id="adcategory" name="adcategory"&gt;
      &lt;option value=""&gt;Select&lt;/option&gt;
      &lt;option value="25" class="dropdownparentcategory"&gt;Florida Atlantic University&lt;/option&gt;
  
      &lt;option value="26"&gt;- Books &lt;/option&gt;
      &lt;option value="27"&gt;- Electronics&lt;/option&gt;
      &lt;option value="28"&gt;- For Rent&lt;/option&gt;
  
      &lt;option value="17" class="dropdownparentcategory"&gt;Florida International University&lt;/option&gt;
  
      &lt;option value="18"&gt;- Books&lt;/option&gt;
      &lt;option value="19"&gt;- Electronics&lt;/option&gt;
      &lt;option value="20"&gt;- For Rent&lt;/option&gt;
  
      &lt;option value="1" class="dropdownparentcategory"&gt;Florida Tech&lt;/option&gt;
      &lt;option value="2"&gt;- Books&lt;/option&gt;
      &lt;option value="3"&gt;- Electronics&lt;/option&gt;
      &lt;option value="7"&gt;- For Rent&lt;/option&gt;
  
  
  &lt;/select&gt;
  </code></pre>
  
  <p>So if the variable for example <code>$school = Florida Atlantic University</code> than show only thoes options witch is till next school category ( <code>.dropdownparentcategory</code> ), so in this case they would be only : </p>
  
  <pre><code>&lt;select id="adcategory" name="adcategory"&gt;
      &lt;option value=""&gt;Select&lt;/option&gt;
  
      &lt;option value="26"&gt;- Books &lt;/option&gt;
      &lt;option value="27"&gt;- Electronics&lt;/option&gt;
      &lt;option value="28"&gt;- For Rent&lt;/option&gt;
  
  &lt;/select&gt;
  </code></pre>
  
  <p>As you can see in this image :</p>
  
  <p><img src="https://i.stack.imgur.com/I69Dx.jpg" alt="enter image description here"></p>
  
  <p>Is it possible to create with jQuery?</p>