jQuery list hide/show based on current class
<p>I want to display the entire ul li struct that has a class <code>current</code> somewhere in it</p>

<p>Every other ul li I want to hide. EXCEPT The top level.</p>

<p>My jQuery is not doing what I want, any suggestions?</p>

<pre><code>$("ul li").find("ul").hide();
$("ul:has(li.current)").parents().show();
$("ul:has(li.current)").children().show();
</code></pre>

<p>For example:</p>

<pre><code>&lt;ul&gt;
    &lt;li&gt;Entire struct is displayed
        &lt;ul&gt;
            &lt;li&gt;1.1
                 &lt;ul&gt;
                     &lt;li class="current"&gt;1.1.1&lt;/li&gt;
                 &lt;/ul&gt;
            &lt;/li&gt;
            &lt;li&gt;1.2&lt;/li&gt;
        &lt;/ul&gt;
    &lt;/li&gt;
    &lt;li&gt;Only this li is shown
        &lt;ul&gt;
            &lt;li&gt;2.1&lt;/li&gt;
            &lt;li&gt;2.2&lt;/li&gt;
        &lt;/ul&gt;
    &lt;/li&gt;
&lt;/ul&gt;
</code></pre>

<p>Displays as:
    <ul>
        <li>Entire struct is displayed
            <ul>
                <li>1.1
                     <ul>
                         <li>1.1.1</li>
                     </ul>
                </li>
                <li>1.2</li>
            </ul>
        </li>
        <li>Only this li is shown</li>
    </ul></p>

<p>EDIT: added children to jQuery, but still not working as desired.</p>
