Posts Tagged: snippet

jQuery thumbnail

Code snippet: Iterate slideshow counter without if/else statements

While scripting a jQuery slideshow gallery, I thought of a way of iterating the counter without needing to use an if/else statement to hard reset it to 0 when it reaches the end of the array. Then do something similar to step from the last slide back to 0. Nothing fancy with this snippet at [...]

Read more

jQuery thumbnail

jQuery nav elements that follow mouse movement

I worked some more on the mouse tracker snippet from yesterday. I managed to smooth out the mouse following animation plus added an end animation that moves the nav button back to the middle after the mouse leaves the slider div. There it is in action: Mouse Track 2 Demo. Again, you need jQuery 1.3 [...]

Read more

jQuery thumbnail

jQuery mouse tracker snippet

While I was doing some script work for a client, I came across the nifty jQuery mousemove property. As this tutorial explains, you can bind the “on mouse move” event and track the pointer position as it moves across the screen. Note: This requires jQuery 1.3. The latest version of jQuery apparently doesn’t work! This [...]

Read more