0

I'm trying to get my shopping cart items to a pdf to create an invoice

I have url which shows the invoice in html/css like this:

index.php?module=checkout&view=topdf

If I want to get the content of that page to use in mPDF or other pdf libraries using file_get_contents or cURL it doesn't give any content because the url is not an actual file on the server

How can I fix this? I work with templates and don't know how can I export the current php page to a html page

1 Answer 1

1

I used TCPDF for something similar. Getting the formatting right is a bit of a pain but once you've got that it's a really good bit of work.

http://www.tcpdf.org/examples.php

Sign up to request clarification or add additional context in comments.

2 Comments

Do you have an example that uses templates and not an actual topdf.php file?
Not to hand but I can try and have a look a bit later on for you. Are you using a shopping cart system?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.