After choosing your image write PHP code to generate graphical letters with colored background as follows. It is assumed that you’ve designed a complete web form with any required controls already, and that form gets the user multi-line string (in this case three lines are provided; you can expand this code to support more lines).
<?php Session_start(); //initializing variables $message1 = POST_[‘msg_1stline’]; $message2 = POST_[‘msg_2ndline’]; $message3 = POST_[‘msg_3rdline’]; $backgnd = POST_[‘image’]; // Save the path where convert is installed in a variable $convert = "/usr/bin/convert"; $mogrify = "/usr/bin/mogrify"; // a function for writing each line of text as a block of letters function write_text(int $x, int $y, string $msg) { //create a new image with the same size as the background //for writing the first line of the letters on $CMD = "$convert size 540x400 xc:transparent line1".strip_tags(SID).".gif"; exec($CMD); for($i=0;$i<strlen($msg);$i++)...