jQuery just recently released their 1.2 version. This spurred me to get some of my mini-projects done and clean up my cookbook area. I also FINALLY figured out how to Gzip my JavaScript files. There might be an easier way, but here is how I did it.
- Rename the JavaScript files from .js to .php. All of them. (And reference them in my html with php, not js.)
- At the top of each JS, I put <?php ob_start(“ob_gzhandler”); ?>
- At the bottom of each JS, I put <?php ob_flush();?>
- Now, all of my JS is gzipped up and much smaller than before. 116k down to 36k!
I couldn’t figure out how to keep them as JS files and still make it work.
Another fun demo I made is a collaboration with Ben Nadel. It’s a nearly useless jQuery Vibrator Plugin. It has one use. It’s sort of fun!
I also have been experimenting with a new API browser for jQuery. This one is much harder to accomplish. I got pretty far last night, but there is alot more to do. I hope I don’t get stuck. I really would like to figure it out. I also added Google Analytics to all of my demos.
So in the past couple of days, I made good progress and completed a few items. I need to follow through and do more.
Whatya think?