Closed Thread Icon

Topic awaiting preservation: myImage.complete ? can someone help me with this? (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=8728" title="Pages that link to Topic awaiting preservation: myImage.complete ? can someone help me with this? (Page 1 of 1)" rel="nofollow" >Topic awaiting preservation: myImage.complete ? can someone help me with this? <span class="small">(Page 1 of 1)</span>\

 
smonkey
Paranoid (IV) Inmate

From: Northumberland, England
Insane since: Apr 2003

posted posted 06-21-2003 15:15

Hi guys,

I'm working on a clever little script that adds a few useability gimmicks to my site. But one of the things I need to be able to do is to trigger a function when each of an array of images has been succesfully preloaded into the cache.

The preload script I'm using is Dreamweaver MX's default, it seems to work adequately enough to me (if you have any stories to the contrary then let me kno).

Now just say I'm preloading 5 images, now what I want to happen is each time one of these images makes it into the users cache I want it to call a function (lets call it 'MyFunc(id)'), and send it's 'id' (it's array number/position) as the argument.

In a previous thread Dracusis mentions something about myImage.complete boolean or something, I'm hoping this can help me out here.

Thanks guys

Dracusis
Maniac (V) Inmate

From: Brisbane, Australia
Insane since: Apr 2001

posted posted 06-23-2003 04:41

This would be a lot easier if you were writing your own preloading script.

As it stands, I doubt many people here have any idea how the dream weaver preloading script works and what you're asking is how to modify it so that you can get what you want.

The problem I see here is that it's going to be very difficult to do what you want to do if you don't understand how to preload using JavaScript. There's been plenty if image preloading questions asked here recently, I suggest you start reading through those and writing some tests to see if you can get what you want. You already seem to know how you'd use the information provided by a preload script, all that's left to do now is to write the preload script.

« BackwardsOnwards »

Show Forum Drop Down Menu