ajax file upload fixes