Solved

PHP/ImageMagick problem making drop shadow

Posted on 2007-04-01
3
631 Views
Last Modified: 2010-08-05
This does not work.

Can anyone please fix it?  Thanks!


                  exec("/usr/local/bin/convert ' . escapeshellarg($im_path . $row->ImageFile) . ' -resize ' . escapeshellarg($Thumb_Width . 'x' . $Thumb_Height . '>') . ' +profile "*" ' . ' -crop '. escapeshellarg($Thumb_Width . 'x' . $Thumb_Height . '+0+0').' +repage -bordercolor red  -border 1 -bordercolor white -border 4 -bordercolor green -background black \\( +clone -shadow 60x4+4+4 \\) +swap  -background blue -flatten  +repage -quality 98 ".escapeshellarg($im_path . 'vita/' . $row->ImageFile), $x, $result);

0
Comment
Question by:hankknight
3 Comments
 
LVL 6

Accepted Solution

by:
deresh earned 500 total points
ID: 18834726
exec("/usr/local/bin/convert " . escapeshellarg($im_path . $row->ImageFile) . ' -resize ' . escapeshellarg($Thumb_Width . 'x' . $Thumb_Height . '>') . ' +profile "*" ' . ' -crop '. escapeshellarg($Thumb_Width . 'x' . $Thumb_Height . '+0+0').' +repage -bordercolor red  -border 1 -bordercolor white -border 4 -bordercolor green -background black \\( +clone -shadow 60x4+4+4 \\) +swap  -background blue -flatten  +repage -quality 98 '.escapeshellarg($im_path . 'vita/' . $row->ImageFile), $x, $result);

there you are, you have wrongly mixed " and ' . don't you use some editor with syntax higlighting ?!

0
 
LVL 16

Author Comment

by:hankknight
ID: 18835537
I use notepad. (Yea, I know I'm crazy!) A good editor might save me some time.....  Any good SIMPLE free editors?
0
 
LVL 1

Expert Comment

by:ajay_chamarthy
ID: 18835583
There you are you did some basic syntax errors as deresh mentioned in using " and '.
I am using Editplus .i downloaded as a trail version and it is working after the time limit also
exec("/usr/local/bin/convert " . escapeshellarg($im_path . $row->ImageFile) . ' -resize ' . escapeshellarg($Thumb_Width . 'x' . $Thumb_Height . '>') . ' +profile "*" ' . ' -crop '. escapeshellarg($Thumb_Width . 'x' . $Thumb_Height . '+0+0').' +repage -bordercolor red  -border 1 -bordercolor white -border 4 -bordercolor green -background black \\( +clone -shadow 60x4+4+4 \\) +swap  -background blue -flatten  +repage -quality 98 '.escapeshellarg($im_path . 'vita/' . $row->ImageFile), $x, $result);

All the best dude :-)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Author Note: Since this E-E article was originally written, years ago, formal testing has come into common use in the world of PHP.  PHPUnit (http://en.wikipedia.org/wiki/PHPUnit) and similar technologies have enjoyed wide adoption, making it possib…
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to count occurrences of each item in an array.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now