PDA

View Full Version : Image Loader



ulhas_math
07-31-2006, 02:35 PM
1) CODE TITLE: Image Loader

2) AUTHOR NAME/NOTES: Ulhas S. Math

3) DESCRIPTION:
ImageLoader script contains a single function to display a loading message until the image loads on the page.It can be called any number of times in the page for mulitple images.USE THE insertImage() FUNCTION WHEREVER YOU ARE USING <img src> tag and pass a unique name to every call of this function. Also you need to pass imageSource and width and height of the MessageBox to be displayed on the image until it loads. For best results it is better to pass the width and height same as that that of the original image. You can also use insertReSizedImage() function if you want to resize the original image to the width and height that you are specifying.

4) URL TO CODE: http://www41.websamba.com/yourInformation/js/imageLoading.js

5) URL TO DEMO: http://www41.websamba.com/yourInformation/loadingCheck.html


or, ATTACHED BELOW (see #3 in guidelines below):

ddadmin
08-01-2006, 08:49 PM
Thanks for the submission. I wan't able to see the "loading" text when viewing your demo unfortunately. Furthermore, considering the pervasiveness of broadband these days, the usefulness of such a script is very limited.

ulhas_math
08-02-2006, 10:07 AM
Yes but this code will be quiet useful when we are generating on the fly images ... like when u specify some action inside the <img src> tag instead of a image url ... I m using it when my image creation process is on java side and always takes some 3-4 secs delay befor displaying the image ....