Is there a tool that will find html tags with class attributes that don't have a corresponding class in CSS?

I found http://www.sitepoint.com/dustmeselectors/ , which does something opposite of what I want, identifying selectors in CSS that are not used in HTML.

I want a tool that will find elements that have a class attribute, but the class is not defined in any CSS loaded by the page.

thank

+1


source to share


3 answers


If the CSS file is correctly linked to your page and part of your project, then in VS.NET 2008 it will give you the standard little scrim warning.



+1


source


There are no tools that I know of.

Seems like a good candidate for a short program as you probably don't need to do this very often.



I would re-output class="someclass"

from my original html, use the web developer toolbar in Firefox to get the concatenation of all my CSS and re-output the `.someclass', then compare the two lists.

0


source


You can do a search with a text editor in your css file for the classes you find in your HTML.

0


source







All Articles