Problems with wkhtmltopdf using VPS Centos Linux
The issue is that I have more than 1 week trying to figure out this:
1.- I did installed correct wkhtmltopdf in my linux vps, using in Command Line works very good example:
/usr/local/bin/wkhtmltopdf -s A4 -B 1 -T 1 -L 1 -R 1 http://www.google.com ../file.pdf
Works good!!!
2.- The problem is When I try to do run the same command line using php files.
Example:
try {
$resultado=shell_exec("/usr/local/bin/wkhtmltopdf -s A4 -B 1 -T 1 -L 1 -R 1 http://www.google.com ../file.pdf > ../debug.log 2>&1");
} catch (Exception $e) {
echo 'Excepcion capturada: ', $e->getMessage(), "\n";
}
It seems that the problem is related to permissions php cpanel or something.
What is your recommendation?
There are many people with the same problem
Thanks!
1.- I did installed correct wkhtmltopdf in my linux vps, using in Command Line works very good example:
/usr/local/bin/wkhtmltopdf -s A4 -B 1 -T 1 -L 1 -R 1 http://www.google.com ../file.pdf
Works good!!!
2.- The problem is When I try to do run the same command line using php files.
Example:
try {
$resultado=shell_exec("/usr/local/bin/wkhtmltopdf -s A4 -B 1 -T 1 -L 1 -R 1 http://www.google.com ../file.pdf > ../debug.log 2>&1");
} catch (Exception $e) {
echo 'Excepcion capturada: ', $e->getMessage(), "\n";
}
It seems that the problem is related to permissions php cpanel or something.
What is your recommendation?
There are many people with the same problem
Thanks!