jQuery Conditional
<p>I simply need to apply a css style to a particular class that meets my criteria.  With a simple array I'm able to do this:</p>

<pre><code>var ins = document.getElementsByClassName('ins');
for(var i = 0; i &lt; ins.length; i++) {
if(ins.item(i).attributes[0].value == "ins right" || ins.item(i).attributes[0].value == "ins left") 
    ins[i].style.width = "120px"; //applies the width to left and right only
}
</code></pre>

<p>What is the equivalent when using jQuery? 
<em>(unfortunately this applies the width to all three elements)</em></p>

<pre><code>if($('.ins').is('.left, .right'))
    $('.ins').css('width','120px');
</code></pre>

<p><strong>Markup:</strong></p>

<pre><code>&lt;div id="wrapper"&gt;
  &lt;div id="outer"&gt;
    &lt;div class="ins right"&gt;
      &lt;p&gt;This is heading 3&lt;/p&gt;
    &lt;/div&gt;
    &lt;div class="ins left"&gt;
      &lt;p&gt;This is heading 1&lt;/p&gt;
    &lt;/div&gt;
    &lt;div class="ins center"&gt;
      &lt;p&gt;This is heading 2 This is heading 2 This is heading 2 This is heading 2 This is heading 2 This is heading 2 This is heading 2 This is heading 2&lt;/p&gt;
    &lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;
</code></pre>
