Added support for AJAX file downloads