This is splorp.

ISSN 1496-3221

|

September 21, 2003

Blocking ads with class and style.

During one of those leisurely Sunday evening strolls through the bookmarks, I discovered a nifty article over at BeatnikPad on how to block ads using CSS selectors. The technique works by defining a series of specific tag and attribute selectors in a personal style sheet, and as described, seems to work in all Gecko-based browsers (Mozilla, Camino, Phoenix, etc.) as well as Safari. Seeing as the original post wasn’t mentioned on too many sites when it first appeared back in March — and quite frankly, it’s a very cool trick — I thought it merited a second look. I’m not that enamored with overriding the style sheets of other sites with my own, but the concept and implementation is very interesting regardless. Selective filtering or tagging of remote content simply by using a customized style sheet could prove to be a powerful tool. Perhaps for aggregating content. Perhaps for reformatting existing content for a particular context within a secondary site. Perhaps creating text-only or light-weight HTML versions of sites that are otherwise clogged with extraneous nested tables and graphics. There are probably a dozen other things I could use this same technique for — I just need to figure out what the heck they are.

This item was posted by Grant Hutchinson.

Categories:

Leave a comment or send a trackback from your own site.

|

Leave a comment.

You may use the following HTML elements and attributes to format your comment:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>