<p>I have a quandary.  My web application (C#, .Net 3.0, etc) has Themes, CSS sheets and, of course, inline style definitions.  Now that's alot of chefs adding stuff to the soup.  All of this results, not surprisingly, in my pages having bizarre styling on occasion.</p>

<p>I am sure that all these styles are applied in a hierarchical method (although I am not sure of that order).  The issue is that each style is applied as a "transparent" layer which just masks what it is applying.  This is, I feel, a good idea as you can specifiy styles for the whole and then one-off them as needed.  Unfortunately I can't tell from which layer the style actually came from.</p>

<p>I could solve this issue by explicitly expressing the style at all layers but that gets bulky and hard to manage and the page(s) works 80% of the time.  I just need to figure out where that squirrelly 20% came from.</p>

[{'answer_id': 54349, 'author': 'Danimal', 'author_id': 2757, 'author_profile': 'https://Stackoverflow.com/users/2757', 'pm_score': 2, 'selected': False, 'text': '<p>in Firefox use the DOM inspector, firebug, or inspect this.<br/>\nin IE, use the IE dev toolbar (or, maybe better, <a href="http://getfirebug.com/lite.html" rel="nofollow noreferrer">Firebug Lite</a>)<br />\nIn Google Chrome, use the built-in "inspect element" functionality</p>\n'}, {'answer_id': 54395, 'author': 'Prestaul', 'author_id': 5628, 'author_profile': 'https://Stackoverflow.com/users/5628', 'pm_score': 4, 'selected': True, 'text': '<p>IMHO, Firebug is going to be your best bet.  It will tell you which file the style came from and you can click on the filename to be transported instantly to the relevant line in the file.  </p>\n\n<p>Note: You can hit <kbd>ctrl</kbd>+<kbd>shift</kbd>+<kbd>C</kbd> on any page to select and inspect an element with the mouse.</p>\n'}, {'answer_id': 54474, 'author': 'Mark Cidade', 'author_id': 1659, 'author_profile': 'https://Stackoverflow.com/users/1659', 'pm_score': 2, 'selected': False, 'text': '<p>Using the <a href="http://www.microsoft.com/en-us/download/details.aspx?id=18359" rel="nofollow noreferrer">IE Developer Toolbar</a> you can select an element (either by "Select element by click" or clicking on its node in the DOM tree view) and in the Current Style pane, right click on a row and select "Trace Style".</p>\n\n<p>The other tools have a similar feature.</p>\n'}, {'answer_id': 54589, 'author': 'jessegavin', 'author_id': 5651, 'author_profile': 'https://Stackoverflow.com/users/5651', 'pm_score': 2, 'selected': False, 'text': '<p>Here\'s a quick sreencast of how to use Firebug to find out from where an element is getting it\'s style.</p>\n\n<p><a href="http://screencast.com/t/oFpuDUoJ0" rel="nofollow noreferrer">http://screencast.com/t/oFpuDUoJ0</a></p>\n'}, {'answer_id': 57354, 'author': 'Community', 'author_id': -1, 'author_profile': 'https://Stackoverflow.com/users/-1', 'pm_score': -1, 'selected': False, 'text': '<p>The key to solving a complex CSS issue is to work out what is causing the weird appearance. The easiest way to find is to selectively comment out stylesheets until you find the one where commenting it out fixes the problem. Then enable the stylesheet and selectively comment out rules until you find the one causing the problem. If you need to know what takes precedence over what, the details of the cascade in CSS is detailed \n<a href="http://www.w3.org/TR/CSS21/cascade.html" rel="nofollow noreferrer">here</a> and unlike the implementation of individual rules, this is fairly consistent across browsers.</p>\n\n<p>However, it is much better if you avoid inline styles entirely and have a set of well-crafted stylesheets, each of which has a logical function and all of whose rules you understand. for the same reason you don\'t put your server-side code in a random order in random files - <a href="http://stackoverflow.com">us</a></p>\n'}]
['https://Stackoverflow.com/questions/54337', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/2894/']