私はimagemagick
convert
phpからコマンドを使用する必要があります。だから私は使用してshell_exec
いますが、その出力はヌル文字列です。コマンド convert はSTDOUTに何も出力しないことを知っていますが、目的の出力convert
も達成されません。もexec
機能しません。これらのコマンドは、シェルまたは php コマンド ラインから正常に実行されます。何が問題になる可能性がありますか?
編集: 2>&1 を追加すると、convert がエラーをスローしていることがわかります:missing an image filename
/a5d98168a524a331c5e06d60096debd63cbdce1f.jpg' @ error/convert.c/ConvertImageCommand/2970. where the full command is
/var/www/weblog/web/uploads/poster/a5d98168a524a331c5e06d60096debd63cbdce1f.png /var/www/weblog/web/uploads/poster/a5d98168a524a331c5e06d60096debd63cbdce1f.jpg を変換します。