Support the ongoing development of Laravel.io →
Database Views Blade
Last updated 2 years ago.
0

Hi, I did something similiar.

First of all I send an ajax request to server with my data for the pdf file. On serverside a create a pdf file with a queue using thujohns pdf package. Because it needs some time, my applications sends an ajax polling request. When it's done, I show a notification with a link to the pdf file.

This is how you can send an ajax polling request:

function doPoll(){
$.post('ajax/pdf', function(data) {
    alert(data);  // process results, notifications etc.
    setTimeout(doPoll,5000);
});
}
0

Sign in to participate in this thread!

Eventy

Your banner here too?

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.