added image extensions, revert function name
do not use pjax for forms with enctype=multipart/form-data