title: Applying CSS property in Jquery
body: <p>I am working on 'OnClick' functionality in jQuery. When we click Div property other divs should fade out. </p>
  
  <p>Please find the code below.
  HTML:</p>
  
  <pre><code>&lt;div&gt;1&lt;/div&gt;
  &lt;div class="ree"&gt;2&lt;/div&gt;
  &lt;div class="foo"&gt;
    &lt;div class = "bar"&gt;
       &lt;div class="nike"&gt;3&lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;
  &lt;div&gt;4&lt;/div&gt;
  </code></pre>
  
  <p>jQuery:</p>
  
  <pre><code>$('.nike').on('click',function ()
                {
  $('div:not(.nike)').css('opacity','0.2')
  
                });
  </code></pre>
  
  <p>Here When I click on Div Class 'Nike', Except 'Nike' all Div classes should fade out. But here All Divs including Nike is fading out.</p>
  
  <p><a href="http://jsfiddle.net/6V8hr/5/" rel="nofollow">http://jsfiddle.net/6V8hr/5/</a></p>
  
  <p>Thanks all</p>