note 108764 added to imagick.construct

From: Date: Wed, 23 May 2012 16:29:36 +0000
Subject: note 108764 added to imagick.construct
Groups: php.notes 
Request: Send a blank email to php-notes+get-188167@lists.php.net to get a copy of this message
If you are using windows imagemagick, at leat in my case, you have to include the full path of the file, including the 'c:' at the beginning. If you don't know for sure the way that the filename is going to come, you can use realpath() function to normalize it: <?php $incoming_file = '/Users/John/Desktop/file_loco.jpg'; $img = new Imagick(realpath($incoming_file)); // realpath() will convert '/Users/John/Desktop/file_loco.jpg' to 'C:\Users\John\Desktop\file_loco.jpg' // and ImageMagick will have no trouble when loading ?> ---- Server IP: 69.147.83.197 Probable Submitter: 190.226.76.180 ---- Manual Page -- http://www.php.net/manual/en/imagick.construct.php Edit -- https://master.php.net/note/edit/108764 Del: integrated -- https://master.php.net/note/delete/108764/integrated Del: useless -- https://master.php.net/note/delete/108764/useless Del: bad code -- https://master.php.net/note/delete/108764/bad+code Del: spam -- https://master.php.net/note/delete/108764/spam Del: non-english -- https://master.php.net/note/delete/108764/non-english Del: in docs -- https://master.php.net/note/delete/108764/in+docs Del: other reasons-- https://master.php.net/note/delete/108764 Reject -- https://master.php.net/note/reject/108764 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#188167) next »