Embark on a journey of knowledge! Take the quiz and earn valuable credits.
Take A QuizChallenge yourself and boost your learning! Start the quiz now to earn credits.
Take A QuizUnlock your potential! Begin the quiz, answer questions, and accumulate credits along the way.
Take A QuizKindly log in to use this feature. We’ll take you to the login page automatically.
LoginGeneral Tech Bugs & Fixes 3 years ago
User submissions are the sole responsibility of contributors, with TuteeHUB disclaiming liability for accuracy, copyrights, or consequences of use; content is for informational purposes only and not professional advice.
It is of course possible, I have done similar things in the past. You can write PHP scripts that call external programs and feed the content of the HTML form fields.
You will need the following:
Concerning your questions on the fields: I have made good experience with templates or even template engines, so what you basically do is to create a LaTeX file as design template. The values that are to be replaced can be masked with special character sequences like "@@customer_name@@" or something similar. What your PHP code then has to do is to:
LaTeX itself has a few data import features, e.g. with the datatool package, but since you need the external call from PHP to latex anyway, you will proably use LaTeX only for the creation of the PDF itself, not the auxiliary tasks involved.
No matter what stage you're at in your education or career, TuteeHUB will help you reach the next level that you're aiming for. Simply,Choose a subject/topic and get started in self-paced practice sessions to improve your knowledge and scores.
Kindly log in to use this feature. We’ll take you to the login page automatically.
LoginReady to take your education and career to the next level? Register today and join our growing community of learners and professionals.
Your experience on this site will be improved by allowing cookies. Read Cookie Policy
Your experience on this site will be improved by allowing cookies. Read Cookie Policy
manpreet
Best Answer
3 years ago
The title needs a bit of help, but I'm wondering if it's possible to dynamically create a beautiful customized receipt for purchases from my website using LaTeX, where LaTeX gets its data from my customer's form entries and my MySQL database. I suspect this is all possible through PHP and some other helping program.
Essentially, in addition to the receipt issued by my payment gateway software, I want to send an additional, but optional, custom receipt PDF to the customer's email, and have this be done on the same machine that my website and database are hosted on.
I'm wondering, in particular, how variables like
customer_nameandproduct_priceandlast_four_digitscan be taken from a submitted customer form entry from mycheck_out.phppage and perhaps from my MySQL database as well can be pulled into LaTeX to manipulate in LaTeX's native variable manipulation language to reorganize into my own custom receipt stylization.In general, just to get me started, what data importing features does LaTeX have to offer? Please provide an example or a link to a resource.