Skip Navigation

[Gelöst] uploading files

This support ticket is created vor 3 Jahre, 2 Monate. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 2 Antworten, has 2 Stimmen.

Last updated by Luit vor 3 Jahre, 2 Monate.

Assisted by: Christian Cox.

Author
Artikel
#1951305

Users can upload files to an e-portfolio. I use the plugin custom upload dir, so files uploaded will be put in ./portfolio/%current_user%/%category%.

For uploads in existing posts this works fine, but the users also create new posts with an upload. For these posts this is not working because at the time of the save, the category is not known yet.

So it looks like the post has to be saved first before a file can be uploaded. Is there a way to solve this issue?

#1952117

Hello, I guess it depends on how your Users create these posts. If Users create posts on the front-end of the site using Forms, then I suppose you could remove the upload field in the Create Post Form and only allow uploads in an Edit Post Form. That might prevent the problem where uploads cannot be categorized in a new post, but requires an additional form submission in the post creation workflow.

Otherwise, I would need to know more about how you want to solve the problem from a Toolset perspective. We offer several APIs that you can use to trigger your own custom code during the Forms submission process, for example cred_save_data and cred_submit_complete: https://toolset.com/documentation/programmer-reference/cred-api/

#1952295

My issue is resolved now. Thank you!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.