jquery: display loader until image exists in a specific folder
I want to display an image loader & keep checking until the image exists in a specific folder.
The images requested are dynamically generated through a queue so I have no idea when the
image will be actually there, but I h开发者_如何学Goave its name in hand.
This process involve two steps
1st: POST request to submit image to queue script. 2nd: display loader until image is actually there, then displaying the image itself.
Your help is greatly appreciated.
you can use jquery image load , it waits until browser loads the image//
but it keeps waiting until the image is ready
http://api.jquery.com/load-event/
精彩评论