title: Is there anyway to know if the css of div is set in class or in id in javascript/ jquery ?
body: <p>Hello I am changing dynamically the css of a website:
  Suppose we have a div:</p>
  
  <p><code>&lt;div id="fooid" class="fooclass" &gt;&lt;/div&gt;</code></p>
  
  <p>with class fooclass and id fooid element and we get its background using: </p>
  
  <p><code>var bgcolor = element.css( "background-color" );</code></p>
  
  <p>My Problem is that I cannot tell of that bgcolor is set in the fooid css or in the fooclass is there anyway to find that out? thank you in advance</p>