THESE CODES ARE PROVIDED FOR AN EXAMPLE OF HOW TO USE IMAGEMAGICK WITH PHP. CARE SHOULD BE TAKEN WHEN ACCEPTING USER INPUT.
I TAKE NO RESPONSABILTY FOR ANY PROBLEMS THAT MAY OCCURE WHEN USING ANY OF THIS CODE.
IT IS UP TO YOU TO SECURE THE CODE AND VALIDATE USER INPUT.
// Create gradiant
exec("convert -size 400x100 gradient:orange-yellow gradiant.png");
//Round the corners and add the text
$cmd = " -size 400x100 xc:none -fill white ".
" -draw \"roundRectangle 0,0 400,100 15,15\" gradiant.png ".
" -compose SrcIn -composite -font $font1 -pointsize 50 ".
" -draw \"gravity center fill red text 0,0 \"Rubblewebs\" \" ";
exec("convert $cmd rounded_gradiant.png ");
unlink("gradiant.png");