Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Output on Front End #72

Open
dskurth opened this issue Nov 7, 2024 · 0 comments
Open

Output on Front End #72

dskurth opened this issue Nov 7, 2024 · 0 comments

Comments

@dskurth
Copy link

dskurth commented Nov 7, 2024

I have succesfully used this library within the backend (dashboard )of a wordpress enviornment. Now I need to create the same PDF, that a user can click on a button and it either displays the PDF file (like in the backend) or allow it to be downloaded. I have tried all the different parameters of Output() as follows:

ob_clean();
$pdf->Output(); // Does nothing

ob_clean();
$pdf->Output('I', ''); // OPENS IN SAME PAGE

ob_clean();
$pdf->Output('D', 'test.pdf'); // Opens file save and then hangs.
$pdf->Output('D', ''); // Opens file save and then hangs.

ob_clean();
$pdf->Output('F', 'test.pdf'); // Should save file, does nothing

How do I achieve this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant