preload files from URL in web application
Posted: Thu Mar 10, 2011 12:07 am
Hi!
I have been struggling with this issue for many days now, I hope someone has ANY clue that can help, please!
Here it's the issue: I am trying to deploy a web application that has a bunch of images from a URL. What's the most effective way to load them?
I thought that loading the URL when opening the stack and starting always from a card that has all the images in it, I could avoid having to hit the server when opening other cards later.
I set up a card that is not accesible with any button from the other cards, and that contains all the images I need to show. Each image object has the source path to a png file in that URL and they are all invisible.
The other cards show some specific images in each one of them, using the IDs of the images in that "hidden" card as icons for transparent buttons.
In the stack code I have:
on openstack
load URL "myserver's http"
go to card "hidden"
end openstack
and then in the "hidden" card I tell it to go to the main card on opencard.
It takes around 30 sec to load the stack and show the main card. Then, when I go to a card that has the same images as the one being currently displayed, it loads instantly, but if the images are different, it takes 5 secs.
Is there a way to load all the files in my URL (server) only once in the beginning and to have them ready/available for every card in the application?
Thank you so much!!!
I have been struggling with this issue for many days now, I hope someone has ANY clue that can help, please!
Here it's the issue: I am trying to deploy a web application that has a bunch of images from a URL. What's the most effective way to load them?
I thought that loading the URL when opening the stack and starting always from a card that has all the images in it, I could avoid having to hit the server when opening other cards later.
I set up a card that is not accesible with any button from the other cards, and that contains all the images I need to show. Each image object has the source path to a png file in that URL and they are all invisible.
The other cards show some specific images in each one of them, using the IDs of the images in that "hidden" card as icons for transparent buttons.
In the stack code I have:
on openstack
load URL "myserver's http"
go to card "hidden"
end openstack
and then in the "hidden" card I tell it to go to the main card on opencard.
It takes around 30 sec to load the stack and show the main card. Then, when I go to a card that has the same images as the one being currently displayed, it loads instantly, but if the images are different, it takes 5 secs.
Is there a way to load all the files in my URL (server) only once in the beginning and to have them ready/available for every card in the application?
Thank you so much!!!