How to use jquery next() to select next div by class
<p>I'm fairly new to jquery and struggling with something that should be fairly simple. I want to select the previous and next div with class "MenuItem" from the div with class "MenuItemSelected".</p>

<p>HTML</p>

<pre><code>       &lt;div id="MenuContainer" class="MenuContainer"&gt;
                &lt;div id="MainMenu" class="MainMenu"&gt;
                   &lt;div class="MenuItem"&gt;
                     &lt;div class="MenuItemText"&gt;Menu Item #1&lt;/div&gt;
                      &lt;div class="MenuItemImage"&gt;images/test1.jpg&lt;/div&gt;
                    &lt;/div&gt;    
                    &lt;div class="MenuDividerContainer"&gt;
                        &lt;div class="MenuDivider"&gt;&lt;/div&gt;
                    &lt;/div&gt;
                    &lt;div class="MenuItem MenuItemSelected"&gt;
                      &lt;div class="MenuItemText"&gt;Menu Item #2&lt;/div&gt;
                      &lt;div class="MenuItemImage"&gt;images/test2.jpg&lt;/div&gt;
                    &lt;/div&gt;
                    &lt;div class="MenuDividerContainer"&gt;
                        &lt;div class="MenuDivider"&gt;&lt;/div&gt;
                    &lt;/div&gt;
                    &lt;div class="MenuItem"&gt;
                     &lt;div class="MenuItemText"&gt;Menu Item #3&lt;/div&gt;
                      &lt;div class="MenuItemImage"&gt;images/test3.jpg&lt;/div&gt;
                    &lt;/div&gt;                                  
        &lt;/div&gt;
</code></pre>

<p>Here is the jquery for next that I thought should have worked.</p>

<pre><code>$('div.MenuItemSelected').next('.MenuItem');
</code></pre>

<p>I also tried</p>

<pre><code>$('div.MenuItemSelected').nextAll('.MenuItem');
</code></pre>

<p>The only thing i could get to work is </p>

<pre><code>$('div.MenuItemSelected').next().next();
</code></pre>

<p>That seems hokey, any ideas?</p>

<p>Thanks.</p>
