Closed MrBaker10 closed 2 years ago
Hi @MrBaker10
Thank you for your message. Seeing your error message it seems like there is an issue in either my dryrun.tex file or with your pdflatex installation.
But because you receive a tex error I guess we can skip the dryrun part and try right away to render something small and save.
Could you try to create a blade file like test.blade.php
and add a simple tex hello world document syntax like this:
\documentclass{article}
\begin{document}
Hello, World!
\end{document}
and then try to download this as a PDF
use Ismaelw\LaraTeX\LaraTeX;
...
return (new LaraTeX('test'))->download('test.pdf');
If this works then it might be an issue with my dryrun code and if it also doesn't work we might have to check further possible issues.
Kind regards, Ismael
Hi @MrBaker10
Have you been able to test my approach? Is there anything I can assist you with?
Kind regards, Ismael
I am very sorry for the late reply. It was due to my installation of texlive. But thank you very much for your effort.
Hi @MrBaker10
No worries. I am glad that you could sort out the issues. If you have any further questions you can always contact me.
I want to run dryRun(), but get the errormessage above. May you can explain me why. Pdflatex works.
Controller public function download(){ return (new LaraTeX)->dryRun(); }
web.php Route::controller(FinposController::class)->group(function () { Route::get('download', 'download')->name('finpos_download'); });
latex.php
<?php
return [ // bin path to your pdflatex installation | use 'which pdflatex' on a linux system to find out which is the path to your pdflatex installation 'binPath' => 'pdflatex', // binPath' => 'c:\Users\itbaecker\AppData\Local\Programs\MiKTeX\miktex\bin\x64\pdflatex',
];