From f9a17b964859e1eb90eea206f7d1212f8b88c104 Mon Sep 17 00:00:00 2001 From: "Gautam krishna.R" Date: Sat, 16 Apr 2016 01:19:31 +0530 Subject: [PATCH] fixes:#6 added wordwarp --- billgen-API.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/billgen-API.php b/billgen-API.php index da27bdb..033d7a7 100644 --- a/billgen-API.php +++ b/billgen-API.php @@ -45,6 +45,7 @@ } else if(filter_input(INPUT_GET, 'text')) { $text=filter_input(INPUT_GET, 'text'); + $text=wordwrap($text,40,"\n",true); } $img = imagecreatefromjpeg('bill-ovl.jpg'); @@ -53,4 +54,4 @@ imagettftext($img, 18, 0, 30, 100, $clr,$font_path, $text); imagejpeg($img); imagedestroy($img); -?> \ No newline at end of file +?>