0

嗨,我使用此代码将 pdf 转换为 swf 我在本地服务器的站点中有 pdf2swf.exe 文件,我想将名为 1.pdf 的 pdf 移动到该 pdf2swf.exe 以使用命令行进行转换,但它不起作用我不知道为什么它的代码enter code here

<?php 

$software_path ="C:\\wamp\www\wellelafa\SWFTools\pdf2swf" ;
$pdf_path ="C:\\wamp\www\wellelafa\SWFTools\1.pdf" ;
$argument = "-o";

$swf_output ="C:\\wamp\www\wellelafa\1.swf" ;

$cmd ="$software_path $pdf_path $argument $swf_output";

$WshShell = new COM("WScript.Shell");


$oExec = $WshShell->Run("cmd /C $cmd ", 0, true); 


?>
4

1 回答 1

0

尝试这个

<?php 

$software_path ="C:\\wamp\www\wellelafa\SWFTools\pdf2swf.exe" ;

$pdf_path ="C:\\wamp\www\wellelafa\SWFTools\1.pdf" ;

$swf_output ="C:\\wamp\www\wellelafa\1.swf" ;

$cmd =$software_path . " -b " .  $pdf_path . " -o "  .  $swf_output";

exec($cmd);

?>
于 2013-09-23T07:50:55.310 回答