How can I get an array of all elements within a specific class using javascript and/or jQuery?
<p>I'm trying to get an array of all elements with the class "sampleclass". For example, withing my document I have three divs:</p>

<pre><code>&lt;div class="aclass"&gt;&lt;/div&gt;
&lt;div class="sampleclass"&gt;&lt;/div&gt;
&lt;div class="anotheraclass"&gt;&lt;/div&gt;
&lt;div class="sampleclass"&gt;&lt;/div&gt;
</code></pre>

<p>I want to get an array with all elements that are within the "sampleclass" using javascipt and/or jQuery.</p>

<p>Any ideas on how to do this?</p>
