PHP Word to pdf-php perform exec to turn Word into PDF permissions issue
Source: Internet
Author: User
Keywordsexec php Word to PDF PHP exec permissions
execphp word go pdfphpexec permissions
Server: ubuntu14.04 php:5.4 apache:2.0 I followed the online search method to install the jdk1.7.0_79,jodconverter-2.2.2, and then use root login to the server, directly enter the command java-jar/alidata1/source/jodconverter-2.2.2/ lib/jodconverter-cli-2.2.2.jar/var/www/wwwroot/upload/doc/test.doc/var/www/wwwroot/upload/doc/' Test.pdf can be transferred, but put this command in the PHP file will not be executed, the return value is always int (127), the result returned with WhoAmI is Www-data, and then I put the server wwwroot, Source is changed from root to Www-data, and the result is int (127), Shell_exec (' WhoAmI '); EXEC (' java-jar/alidata1/source/jodconverter-2.2.2/lib/jodconverter-cli-2.2.2.jar/var/www/wwwroot/upload/doc/ Test.doc/var/www/wwwroot/upload/doc/test.pdf 2>/var/www/wwwroot/log.txt ', $arr, $res); Var_dump ($arr, $res); ?> This catch log, get is sh:1: Java:not found. Is there any great God who knows whether this is a matter of authority or not, and how should it be adjusted? Thank!
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.