jQuery - Selecting children by class using parents ID.
<p>I'm using the <a href="http://manos.malihu.gr/jquery-custom-content-scroller" rel="nofollow">MCustomScrollBar</a>  , but have multiple instances of the scrollbar on the page. I need to be able to target <code>.mCSB_container</code> to append <code>&lt;li&gt;</code>elements dynamically to each of the scrollbars separately .</p>

<p><a href="http://stackoverflow.com/questions/12779312/how-do-i-dynamically-find-out-what-the-id-or-class-of-a-div">This</a> is the same question essentially, but the accepted answer won't work , as its trying to get the id using attr , where the class does'nt have an id. </p>

<pre><code>&lt;div id="titles" class="scroll-box" style="opacity: 1; "&gt;

    &lt;h2&gt;Latest Titles&lt;/h2&gt;
    &lt;ul class="scroll-horizontal mCustomScrollbar _mCS_1"&gt;
         &lt;div class="mCustomScrollBox mCSB_horizontal" id="mCSB_1" style="position:relative; height:100%; overflow:hidden; max-width:100%;"&gt;
             &lt;div class="mCSB_container" style="position: relative; left: 0px; width: 2860px; "&gt;
                 &lt;li class="product-car"&gt; My Car&lt;/li&gt;
                 &lt;li class="product-bike"&gt; My Bike &lt;/li&gt;
                 &lt;li class="product-tree"&gt; My Tree &lt;/li&gt;
             &lt;/div&gt;
         &lt;/div&gt; 
    &lt;/ul&gt;

 &lt;/div&gt;
</code></pre>

<p></p>

<pre><code>    &lt;h2&gt;Latest Houses&lt;/h2&gt;
    &lt;ul class="scroll-horizontal mCustomScrollbar _mCS_2"&gt;
         &lt;div class="mCustomScrollBox mCSB_horizontal" id="mCSB_2" style="position:relative; height:100%; overflow:hidden; max-width:100%;"&gt;
             &lt;div class="mCSB_container" style="position: relative; left: 0px; width: 2860px; "&gt;
                 &lt;li class="product-house"&gt; My House&lt;/li&gt;
                 &lt;li class="product-boat"&gt; My Boat &lt;/li&gt;
                 &lt;li class="product-tree"&gt; My Tree &lt;/li&gt;
             &lt;/div&gt;
         &lt;/div&gt; 
    &lt;/ul&gt;

 &lt;/div&gt;
</code></pre>

<p>So I've tried playing around using <a href="http://api.jquery.com/children/" rel="nofollow">jQuery children</a> but to no avail. </p>
