Solved

CSS Cleaner or Code Compare

Posted on 2015-02-18
3
144 Views
Last Modified: 2015-02-18
Out of curiosity, is there an online service or download that will compare a website and the CSS file to see if there are entries within the CSS file that are not being used anywhere on a website?

I think I have a bunch of bad/old/unused CSS entries in a certain file.
0
Comment
Question by:rgranlund
3 Comments
 
LVL 70

Assisted Solution

by:Jason C. Levine
Jason C. Levine earned 250 total points
ID: 40617132
There are several.

The DustMe FireFox extension: https://addons.mozilla.org/en-US/firefox/addon/dust-me-selectors/

A JQuery script: http://joaquinnunez.cl/blog/2009/10/06/jquery-css-cleaner/

The BeeCSS markup generator: http://beecss.theextremewebdesigns.com/

That last one is sort of "detect by proxy."  You paste in your HTML and it returns a blank CSS sheet with the selectors used in the HTML.  Given that, you can figure out what isn't be used from your current stylesheet.
0
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 250 total points
ID: 40617210
I use the  CSS Usage 0.3.3  Add-on in Firefox.  It will check your CSS and provide a 'cleaned' version if you ask for it.  https://addons.mozilla.org/en-us/firefox/addon/css-usage/
0
 
LVL 7

Author Closing Comment

by:rgranlund
ID: 40617245
Thanks!  I had no idea these were available.
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article discusses how to create an extensible mechanism for linked drop downs.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now