Strange problem with convert
Posted: 2013-09-03T05:08:17-07:00
Hi,
I'm in a strange problem. I'm trying to export brytum gantt chart in pdf/png.
I'm about to complete the export, but a strange problem i'm facing.
This is one of my code sample.
here, in the exec function command is not executing successfully.
I've got the value of $cmd which is : convert D:\PHP\xampp\htdocs\export/print-1378204549859.png D:\PHP\xampp\htdocs\export/print-1378204550271.png "D:\PHP\xampp\htdocs\export/complete-exportedPanel0.634509001378204542.pdf"
If i run this command from command prompt, then the command is executing successfully, even it is write a block of code in another php file like :
at this time also the pdf is creating. But bad luckily, in the project, the pdf is not creating.
I've no idea, why this is not working under the project. But i'm getting the same value in $cmd variable.
Please help me someone. This strange problem is ruining my all day long. Sorry for my bad english
Thanks
Dhrubo
I'm in a strange problem. I'm trying to export brytum gantt chart in pdf/png.
I'm about to complete the export, but a strange problem i'm facing.
Code: Select all
$imgkOut = array();
//run imagemagick merging separate png's into one pdf or png depending on the file format
if ($fileFormat == 'pdf'){
$cmd = $imgkPath.'convert '.$pdfs.' "'.$outputPath.'/'.$out.'"';
} else {
$cmd = $imgkPath.'montage -mode concatenate -tile 1x '.$pdfs.' "'.$outputPath.'/'.$out.'"';
}
exec($cmd, $imgkOut);
here, in the exec function command is not executing successfully.
I've got the value of $cmd which is : convert D:\PHP\xampp\htdocs\export/print-1378204549859.png D:\PHP\xampp\htdocs\export/print-1378204550271.png "D:\PHP\xampp\htdocs\export/complete-exportedPanel0.634509001378204542.pdf"
If i run this command from command prompt, then the command is executing successfully, even it is write a block of code in another php file like :
Code: Select all
$imgkOut = array();
$cmd = 'convert D:\PHP\xampp\htdocs\export/print-1378204549859.png D:\PHP\xampp\htdocs\export/print-1378204550271.png "D:\PHP\xampp\htdocs\export/complete-exportedPanel0.634509001378204542.pdf"';
$imgkOut = exec($cmd);
I've no idea, why this is not working under the project. But i'm getting the same value in $cmd variable.
Please help me someone. This strange problem is ruining my all day long. Sorry for my bad english
Thanks
Dhrubo