Monday, 15 September 2014

PHP Execute bat file on windows server -



PHP Execute bat file on windows server -

i have php file creates pdf fill form , uses pdftk merge info template.

i having problem getting php execute batch file in order run programme , merge it.

$current = '\\oma-entfs-002\aps\wwwroot\tuition\uploads\';

my php code:

$wshshell = new com("wscript.shell"); $wshshell->exec($current.'makepdf.bat ' .$fdf_file.' '.$newpdf);

the batch file:

pushd \\oma-entfs-004\aps\wwwroot\tuition pdftk uploads/educational_assistance_request_form_north_america.pdf fill_form uploads/%1 output uploads/%2 need_appearances popd

both com , exec enabled on server far can tell.

when run batch file command line, works fine think there php not running file correctly.

any suggestions on best way debug , identify root cause?

php windows batch-file pdftk

No comments:

Post a Comment