I have some code a little like this...
<img src="..." width="100" height="100" alt="" onclick="FlipImg(1234)" />
There are lots of these images on the page, each with a different id in the FlipImg()
call.
I normally prefer to put this type of code into a bit of jQuery, maybe a little like this...
$("img").click(FlipImg(<id from somewhere?>));
However, I can't figure out where to store the id that I need to pass to the code (title is already being using to contain, well, the title of the image, and id is already being used for something else).
Can anyone suggest a way of getting my onclick code out of the html and into my javascript file where it belongs?