i need to make a image id card from data in my database and make it into a image and i have this so far: but it doesn't do line breaks that is what im struggling to sort out.
session_start();
// create an image with width 100px, height 20px
$image = imagecreate(200, 100);
// create a red colour for the background
// as it is the first call to imagecolorallocate(), this fills the background automatically
$red_background = imagecolorallocate($image, 255, 0, 0);
// create a black colour for writing on the image
$black = imagecolorallocate($image, 0, 0, 0);
$info='Message \n Hello';
// write the string "vdhri.net" on the image
// the top left of the text is at the position (10, 2)
imagestring($image, 4, 10, 3, $info, $black);
// output the image
// tell the browser what we’re sending it
Header("Content-type: image/png");
// output the image as a png
imagepng($image);
// tidy up
imagedestroy($image);