469,909 Members | 1,698 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,909 developers. It's quick & easy.

Preload many images

I have tried several preload scripts found here; plus, some of my own.
The only thing that works is the unsophisticated loading of those
tiny images. The download consist of 100+ images amounting to 50+mb;
and, normally completes in less than 1 minute without preload (using
DSL). The preload terminates after 6 or 7
images and seems to time-out in the middle of an image. A reload will
download a few more, etc. I have used the <body onLoad=function()>
approach as well as the
non-function approach of JS that executes immediately with the page's
loading.
Getting the same results with Netscape-7 and IE-6.

I need to add: The source of the array containing the image
references is a '.js' file. That doesn't seem pertinent as some of the
images always load.

Got any ideas??

Tx Albert Spencil
Jul 23 '05 #1
2 3190
Albert Spencil wrote:

I have tried several preload scripts found here; plus, some of my own.
The only thing that works is the unsophisticated loading of those
tiny images. The download consist of 100+ images amounting to 50+mb;
and, normally completes in less than 1 minute without preload (using
DSL). The preload terminates after 6 or 7
images and seems to time-out in the middle of an image. A reload will
download a few more, etc. I have used the <body onLoad=function()>
approach as well as the
non-function approach of JS that executes immediately with the page's
loading.
Getting the same results with Netscape-7 and IE-6.

I need to add: The source of the array containing the image
references is a '.js' file. That doesn't seem pertinent as some of the
images always load.

Got any ideas??

Tx Albert Spencil


Albert,

If you show us some code, we may be able to help.

J.
Jul 23 '05 #2
Juliette <"jrf[spamblock]"@jokeaday.net> wrote in message news:<40***************@jokeaday.net>...
Albert Spencil wrote:

I have tried several preload scripts found here; plus, some of my own.
The only thing that works is the unsophisticated loading of those
tiny images. The download consist of 100+ images amounting to 50+mb;
and, normally completes in less than 1 minute without preload (using
DSL). The preload terminates after 6 or 7
images and seems to time-out in the middle of an image. A reload will
download a few more, etc. I have used the <body onLoad=function()>
approach as well as the
non-function approach of JS that executes immediately with the page's
loading.
Getting the same results with Netscape-7 and IE-6.

I need to add: The source of the array containing the image
references is a '.js' file. That doesn't seem pertinent as some of the
images always load.

Got any ideas??

Tx Albert Spencil


Albert,

If you show us some code, we may be able to help.

J.


OK. This is a very simple one. For NS4.7 it preloads anywhere from 2
to all (79). For NS7x it preloaded 7 and on restores it downloaded a
few more each time. For IE6 it consistently preloads just the last
image (#79).

<script src='imageFile.js'></script> // contains the array 'pics'
<script language='javascript'><!--
/*-------------Function to preload images----------------*/

function doPreload()
{

for(loop = 0; loop < pics.length; loop++)
{
var an_image = new Image();
an_image.src = pics[loop];
}
}
/*-------------------------------------------------------------------*/
//-->
</script>
</head>
<body onLoad=doPreload() bgcolor="#004f00" text="#ffffff"
link="#ffffff" vlink="ffffff" alink="ffff48">
Jul 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by MALdito | last post: by
3 posts views Thread by Bob | last post: by
2 posts views Thread by jmhill | last post: by
1 post views Thread by Stacey | last post: by
9 posts views Thread by shapper | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.