I have a php script that: compresses and sends to the server images uploaded by the user, sends the text inputs as email, and then does a redirect with header('location:...'). So, the user needs to wait for this process's finishing to be redirected to another page. It takes too much time to keep them waiting. How could I work around this problem? I really appreciate any help you can provide.
Asked
Active
Viewed 48 times
0
-
Nope. And the reason: https://stackoverflow.com/questions/2929939/redirecting-before-post-upload-has-been-completed – D A May 13 '22 at 13:06
-
You could try doing the upload via AJAX, and meanwhile opening the next page in a new tab/window. Depends how you want the UX to work, though. – ADyson May 13 '22 at 13:19
-
@ADyson, yes, I'm figuring out about asynchronous file uploading with ajax, ty – Kmdd May 13 '22 at 13:25