Often, you want an image to respond to the user's actions. The most used and theoretically simplest way to accomplish this is through rollovers. There is a technique and etiquette to creating rollovers, and this exploration looks at some pitfalls and reminders when tackling them. Several times you download a rollover script from a site that uses it, and spend a good hour or two decoding and repurposing it. Well this is where knowing a little bit about the rollover comes in handy.
Lets talk a bit about the steps and concept behind making a rollover work.
Here are the basics of rollovers and a glimpse into the JavaScript language. Fear not young brave ones, we aren't taking a JavaScript course here, just using it for what we need it to do. So we would assume that somewhere that number would reappear. The actuality of how JavaScript reads the page is that it stores your first image as 0, and the second as 1. So the rule of thumb when using this list is to subtract 1 from the actual number at which the image appears.