add file upload method.