added custom filename support for uploads and attachments