I have run this command in shell_exe()
function as shown below:
shell_exec('/usr/bin/soffice --headless --convert-to html:HTML --outdir /home/admin/Desktop/ /home/admin/Desktop/text.docx');
But it gives me error like this in apache error log:
Error: Please reverify input parameters...
The error you have received is not PHP / apache related.
It is an
soffice
output.So
shell_exec()
works without problems even the executed command returned an output that was passed back to theshell_exec()
function.How to run
soffice
I recommend search forums like: https://ask.libreoffice.org/en/question/2641/convert-to-command-line-parameter/To receive the error output is better to use
exec()
function instead ofshell_exec()
getting output and exit status from shell_exec()
https://unix.stackexchange.com/questions/15264/executing-a-shell-command-from-php-with-shell-exec