Where is a configuration file of ImageMagick?

Post your questions about Web Server usage and Apache + PHP + MySQL/SQLite web applications.
Post Reply
monchaikwsp
New here
Posts: 5
Joined: Mon Mar 22, 2021 5:03 pm

Where is a configuration file of ImageMagick?

Post by monchaikwsp »

I known 'policy.xml' is a configuration file of ImageMagick. But it is not in QNAP! I would like to change some of configure value that is not allow to open a pdf file and convert to jpg. Thank you.
monchaikwsp
New here
Posts: 5
Joined: Mon Mar 22, 2021 5:03 pm

Re: Where is a configuration file of ImageMagick?

Post by monchaikwsp »

I tested this code.

<?php
$im = new Imagick('test.pdf[0]');
$im->setImageFormat('jpg');
header('Content-Type: image/jpeg');
echo $im;
?>

And error log is look like this.

PHP Fatal error: Uncaught ImagickException: attempt to perform an operation not allowed by the security policy `PDF'.
monchaikwsp
New here
Posts: 5
Joined: Mon Mar 22, 2021 5:03 pm

Re: Where is a configuration file of ImageMagick?

Post by monchaikwsp »

After I installed 2 qpkgs :-
1. ImageMagickQ8_7.0.7.28_x86_64.qpkg
2. GhostScript_9.50_x86_64.qpkg

Now is ok. If who would like to get more information, I gladly recommend.
Post Reply

Return to “Web Server & Applications (Apache + PHP + MySQL / SQLite)”