Me drive truck good
2009.09.29
Me drive truck good
2009.09.19
2009.09.18
After brunch @ Marmalade Cafe, we went h
2009.09.17
2009.09.10
Lightning Storm
This spectacular lightning storm was isolated inside a cumulus cloud. Celeste filmed with our point and shoot camera over at Karen and Thorin’s place in Sarasota, FL. The low quality video doesn’t really do justice to the amazing visual beauty.
2009.09.05
Fading Images with jQuery
I just started using the jQuery javascript framework to replace my home-grown animation functions. It is really helpful in speeding up development and is cross-browser compatible so it also cuts down on QA testing. Below is a little bit of jQuery code for swapping out images:
function imgin () {
$( '#img-id' ).attr ( { 'src': new_img_url } );
$( '#img-id' ).load ( function () {
$( '#img-id' ).fadeIn ( 1000 );
} );
}
$( '#img-id' ).fadeOut ( 200, imgin );
Start by setting a 200 millisecond fadeOut on the current image with a callback to imgin function. imgin sets the src attribute (via the attr method) of the image to load the new image file (via new_img_url variable). Then set a load event on the image to trigger fadeIn after the image is loaded.