baguus

Download starts before the file is created

Posted 1 year ago by baguus

Hi guys, I want to create 1 - 10 excel files, compress them to .zip and download. I use maatwebsite/excel to create the files and store them in the temporary folder and this works. I use Zipper to zip the files in the temporary folder and download them. I get the error that the zipped file doesn't exist. If I run the download again (press the download button) the file is downloaded.

How can I "delay" the download until the .zip file is actually created?

Is there a better procedure to complete this task? It would be best if I didn't have to store the files on server at all as I need to delete them after the task.

Please sign in or create an account to participate in this conversation.

Reply to

Use Markdown with GitHub-flavored code blocks.