The code shows that for each image there can be a unique link. You'd want to slow them down to 3 seconds or more each to use different links, as well as having different ads on each image. The way the code is now, any click will get you to the same link, and the images are one subject only. The timing is currently 1/2 second, which is gotten with the
millisecondtimer = 500 variable. The images are set to cycle forever, but you could have the last image be the critical one and stop it there by removing the
if (thecount == numpics) {thecount = 0} code.
You may use this technique to present pop-up ads, or to solicit subscribers to your ezine, newsletter, or RSS feed. Use if for reminders, warnings, or statistics displaying. You may get survey participants, ask for donations, or use it for political fund raising. You can even inform visitors about some of your other related websites. There is no end to the types of purposes that pop-ups can be used for.
If your pop-up is about thumbnail enlargement, check out
What is the easiest way to do thumbnail image enlargement windows? If you want thumbnail enlargement without clicking, check out
Making an Image Enlarge When The Mouse Cursor Is Hovering Over It.