Handy CSS Cleanup Tool

Dust-Me Selectors

Inevitably, when finishing development of a front-end, I find myself going through the painstaking process of cleaning up extraneous CSS styles. This style was for debugging, this block was for a page that got nixed, this piece I used when conceptualizing the site another way: I don’t think it’s possible to develop a website without removing some styles at the end. Dreading another round of CSS cleanup, I considered programming a tool to spider a site and tell me which parts of the stylesheets were used. It seemed a daunting task so I checked online, and sure enough, someone had already developed it, and far better than I could have. The tool I found, Dust-Me Selectors, is a Firefox extension that makes cleaning up CSS a snap. It can spider an entire site or a group of pages to determine which CSS blocks are unused … Read more…


jQuery Video Game Remake: T&C Surf

T&C Surf Designs

When I was seven, my all-time favorite video game was T&C Surf Designs for the 8-bit Nintendo® (NES). Feeling nostalgic this weekend, I developed a version of this old school game using jQuery and Javascript.

Up and Down to move, Left and Right to skate faster or slower, Spacebar to jump

After playing Javascript Mario Kart, I’ve been wanting to develop a classic video game with jQuery. T&C seemed like a good fit because its motion and overall simplicity are ideal for jQuery’s animation library (and it’s really fun).

I’m fairly pleased with the performance, which is vastly improved through the use of cell-based collision detection. Instead of having to check for collision every pixel, it can be checked every 32, with huge processing savings. Additionally, the use of CSS sprites greatly reduces the number of HTTP requests and the need to use … Read more…


A Simple jQuery Slideshow

Simple jQuery Slideshow Tutorial

In the interest of following jQuery’s motto of “writing less and doing more,” let’s write a simple slideshow using jQuery, JavaScript and a bit of CSS.

For starters, our main goal should be keeping the markup as clean as possible: <div id=”slideshow”> <img src=”img/img1.jpg” alt=”" class=”active” /> <img src=”img/img2.jpg” alt=”" /> <img src=”img/img3.jpg” alt=”" /> </div> Now let’s use CSS to position the images on top of each other and bring the active image to the images on top of each other and bring the active image to the top level with z-index:


5 Performance Tuning Tricks for jQuery

5 Performance Tuning Tricks for jQuery

In a recent post, I wrote that developers should better optimize their JavaScript. Well, that’s easier said than done, so I’d like to get down to the nitty-gritty and talk specifically about optimizing jQuery. Please note that this is not about performance tuning of the jQuery library, rather it is about better engineering the code we use to interact with it. If you’re not a jQuery programmer, and you have no interest in joining the fad, don’t worry—most of the concepts here apply to JavaScript and general programming as well.

1. Beware of class-only selectors

A great part about using a JavaScript library like jQuery is its selectors. But before you use them all over the place, stop to think: what are the processing costs?

Basically, jQuery defines all the elements on a page as a huge JavaScript object, … Read more…


Too much Javascript? Here comes WebKit and the new Safari

Too much Javascript?  Here comes WebKit and the new Safari

Let it not be said that I never fall victim to a web fad: AJAX, jQuery, SEO‚ÄîI was there with bells on. So when everyone started hating Flash and doing all web animation with HTML/Javascript, I jumped right on board. I thought it was just great! You didn’t have to lose any SEO, and most importantly you never had to open that awful Flash GUI.

But have you noticed? EVERYONE ELSE IS DOING IT! There’s just too much Javascript on the internet these days, and it is bringing many browsers to a halt. My MacBook is less than a year old (2.1GHz, 1GB mem) and Safari has been crashing frequently. In Firefox I can only have three or so tabs open before serious lag1. While I don’t have a super gaming computer, my computer is better than the average user’s, and I … Read more…


Dashalytics: Google Analytics for Mac OSX

Dashalytics: Google Analytics for Mac OSX

If you’re anything like me you open up Google Analytics with your morning coffee, check your email, then reload Analytics, just in case the cache has refreshed. There’s a new version of an OSX dashboard widget, Dashalytics, that will revolutionize the amount of time you can spend obsessing over minute statistics. Dashalytics puts Google Analytics at your fingertips, providing a quick access point to some of the most used Analytics reports, directly from the dashboard in Mac OSX.

How to use Dashalytics

Configuring Dashalytics is simple, just enter your Google Analytics account information; it even supports multiple Analytics accounts through the keychain on OSX. After logging in, you are able to access the three most used tabs: visitors, content, and traffic sources. Within each of these tabs, there are three different reports, but these sub-reports are essentially only the overview of each tab.

Additionally, Dashalytics provides common … Read more…


Lumifi – Web Search Without a Web Browser

Lumifi – Web Search Without a Web Browser

There’s a new search engine being showcased on Apple.com’s widget download page, lumifi® , which, unlike other search engines, does not run through a web browser. With web search being so integral to our computer lives, is it preferable to search through a website or an application?

Lumifi’s marketing department provides one answer :

“lumifi is different than Google and other search engines in that it reads each search result for you to determine what is actually relevant to your research rather than what happens to be popular at the moment.”

But obviously other search engines do relevance tests–determining relevance is their main purpose. Perhaps they mean that lumifi does some sort of post-processing of standard search results; basically a double-search. Their program hits Google, or some other search engine, then filters and returns the reordered results.

The problem is the results are pretty lousy. Google‚Äôs algorithm is great … Read more…


Spaces in Mac OSX Leopard – Best Workflow

Mac OSX Leopard

At first glance Mac OSX Leopard looks like Tiger with a new, sleeker skinning. A few new applications are available, and a few others are broken, but overall basically the same thing. That is, until you discover the Spaces command.

Spaces are great, they’re like the Expose flyout but taken up a level. With Spaces, you can arrange all the windows on your screen, all the clutter, into multiple, separate areas. Each of these areas functions like its own desktop, when you use the Expose flyout, only the windows in that Space are seen. And the best part is that you can set programs to open by default in certain spaces. I love this feature, since I am always working on such disparate things. Now my web development can be separate from my web design and … Read more…


jQuery Animation and SEO

jQuery Animation and SEO

I put a bit of jQuery on my site, animating the links in my art portfolio section. Check it out. I really like jQuery actually, it looks nice, and its a great way to liven up a site’s visuals without using Flash and losing all that SEO.

The problem is that jQuery, which is essentially JavaScript, is also not very SEO friendly. You can use it pretty much the same way as Flash, in limited quantities where you don’t care about searchability. However, when you want to make it SEO friendly, it operates pretty similarly to AJAX. Basically, you don’t want jQuery to be the only way you access any content. Any content that is accessed with jQuery also needs to have hard links, anchor tags with the href to make the search engines happy. These anchor … Read more…


Lower Case Months Plugin for WordPress

Wordpress plugin

This WP plugin is kind of pointless, since you can modify text capitalization via the CSS text-transform property: lowercase, capitalize and uppercase are all options. more info

While doing some WordPress customization recently, I ran into a problem forcing lower case output for the month headers in my blog archives.

It seems like a simple task but it turns out the WordPress templating engine prevents you from returning any strings from functions while within a template. You can use all the PHP you want, and call any function you want, but the functions in the end work by echo’ing out a result, rather than returning it. This seems like a pretty good security move, but it turns out to be pretty annoying when you’re used to object oriented code and you want to do something simple like make an … Read more…