Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Feedback on: Displaying Temporary Pages

irt.org | About | Feedback | 1494 [ previous next ]

Feedback on:
Displaying Temporary Pages

Sent by
Peter Wilson on July 15, 2000 at 11:09:23:

Worth:
Very worth reading

Comments:
Why have a variable for each image, if you know that you have N images to load why not maintain a count of images already loaded? This should simplify and generalize the code.

var numberOfImages = 5;
var numberOfImagesLoaded = 0;
function checkImage() {
numberOfImageLoaded++;
if (numberOfImagesLoaded >= numberOfImages) {
...
}
}


Other feedback on 'Displaying Temporary Pages' - show all


Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 21st December 2007. Maintained by: Martin Webb
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2008 irt.org, All Rights Reserved.