Avatar of ivanblue
ivanblueFlag for United States of America asked on

Rename and copy file uploaded using Jquery-File-Upload

Hello, I'm using JQuery File Upload plugin https://github.com/blueimp/jQuery-File-Upload, but I don't know how to copy the file when is up and rename it. I'm using PhalconPhp framework.

This is the javascript:

        url: "/userattachment/upload",
        dataType: "json",
        done: function (e, data) {
            $.each(data.result.files, function (index, file) {

Open in new window

And in the controller:
public function uploadAction()
	$upload_handler = new UploadHandler();

Open in new window

Please help, thanks.

Avatar of undefined
Last Comment
Ray Paseur

8/22/2022 - Mon
Ray Paseur

Phalcon is very new, so new that I cannot find another PHP professional among my colleagues who has ever used it!  So rather than try to do original research, I'm just going to suggest that you take this question to their support team.

Yes, it's new, but my question it's not necessarily attach to the framework. I provided that info in case it was useful.

I just need to be able to use or configure the php class provided by jquery-file-upload "UploadHandler" which is already in the upload controller. I need that class to copy the uploaded file to /var/files/ and be able get original filename and be able to rename it.

This class is already functioning, I just need to change a little what it does.

Ray Paseur

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck