How can I send PDF file from my angular fronted to my laravel backend
问题 I'm trying to send a PDF file created in angular, By the jsPDF plugin to my laravel backend. I tried getting the base64 datauristring. And sent it to the backend. Then I used the base64 decode and wrote it to storage. But I was unable to get the exact PDF file there was an error saying the file is broken . 回答1: It depends on how you convert your page to pdf. If you use addHtml() , your datauristring starts with something like this data:application/pdf;base64 . But if you use newer version