Best answer

File upload to Wordpress: How to automatically infer file type (jpg, png, mp4, etc)

  • 27 May 2020
  • 1 reply
  • 123 views

I have a Zap that connects Typeform to Wordpress.

In my Typeform form I have a field in which I let users upload a file, ideally image or video, but could be a ZIP too.

In my Zap there is a step that uploads this submitted media to Wordpress. In this step I have to specify “filename” and “file”. The “filename” part is the problematic one:

  1. If I don’t add an extension to the filename, the Zap will fail with the message: “Fault (code 500) occurred. Message: Could not write file xyz (Sorry, this file type is not permitted for security reasons.)”
  2. If I add an extension to the filename (e.g. jpg) it will work BUT it will not be the correct filename for a lot of submitted files (causing problems later in Wordpress)

Has anybody had a similar problem? Is there a solution?

Many thanks in advance!

icon

Best answer by Danvers 29 May 2020, 09:47

Hi @alexabruck! Welcome to the Community!

 

 Unfortunately, there isn’t a way to upload a file without including the file extension in the name and there isn’t a way to edit the filename after it’s uploaded using Zapier. I’m sorry that there’s not a workaround for this one 😞

View original

This topic has been closed for comments

1 reply

Userlevel 7
Badge +11

Hi @alexabruck! Welcome to the Community!

 

 Unfortunately, there isn’t a way to upload a file without including the file extension in the name and there isn’t a way to edit the filename after it’s uploaded using Zapier. I’m sorry that there’s not a workaround for this one 😞