Some updates for newer jQuery. (Sorry about the reformat)

Added error handling to progress ajax.
Updated for jQuery 1.9+ where $.browser has been removed.