I think redirect tells the browser to redirect aka make anew request. So when eturn $pdf->download('po.pdf') is returned, PHP is no longer running.
What do you want to achieve? Do you want to show iew('purchaseOrders.poCreate', compact('variables');' as PDF?
or download pdf file, then take user to order form? Other way around could work by using javascript. But would not make much sense
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community