Change Name of uploaded files in powermail formular on typo3

老子叫甜甜 提交于 2020-01-06 07:58:08

问题


i hope someone could help me with my question.

I have on a typo3 site a form for applications. On this form you have the ability to upload different documents for curriculum vitae and certificates. This form is created with a powermail plugin.

The email, generatedfrom the form, should pass a gateway and automatically inserted into a database. And I got some problems with the files.

  1. The files should not have the same name. If a candidate load up files with the same name the gateway can not see, which one is for vitae and which for certificate.

  2. Typo3 put every file in one folder and put a suffix on it when there is already a file with that name. But this suffix is not reportet to the email. So when i got the email it says for example the file for certificate is "certificate.pdf" but the real name of the file is certificate_2.pdf

I think the best way to solve the problems is, to give the files an unique praefix. So the candidade upload a file xxx.pdf for certificate, but the form change the name to certificate_xxx.pdf before it was send.

Or the suffix would be also displayed in the email and not only in the file name.

I hope that is understandable (sorry, english is not my native) and someone could help me.

Greetings Thomas


回答1:


If you try to upload two files with the same name and powermail can not handle it, this is a bug. In this case: Pls report to github!

But, powermail can randomize filenames if this is an option to you: https://github.com/einpraegsam/powermail/blob/develop/Configuration/TypoScript/Main/setup.txt#L538



来源:https://stackoverflow.com/questions/48338988/change-name-of-uploaded-files-in-powermail-formular-on-typo3

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!