We're loading content via ajax using .load, into a jquery ui dialog
box.

Everything is fine but I'd like to have a loading animation until the
ajax content is ready to go

I tried something along the lines of:

- put a loading animation in "#divForDialog"
- $(divForDialog).dialog().load( 'page.htm')

so the loading animation displays when the dialog pops up, and then
ajax loads content that erases the loading animation

it's fine except that the ajax content still takes a while to load,
but the system erases the loading animation the moment it receives
some of the ajax content

another complication is that the ajax content pulls in images etc via
css and via jquery.css('background-image' : 'url(path/to/file.jpg)')
type calls

I'm sure there must be an easy way to make the .load wait till the
ajax content is 100% done loading before injecting the content?

Reply via email to