Hey,
I made myself a randomized quote selector for a signature script, but some of the quotes I am using are rather long and run off the image. I tried using \r\n inside the strings to make em go over to the next line, but that only comes up as weird symbols on the image.
<?php
$image = "signature.png";
$im = imagecreatefrompng($image);
$white = ImageColorAllocate ($im, 255, 255, 255);
$usedquote = rand(0,13);
$quote[0] = "Quote";
$quote[1] = "Quote";
$quote[2] = "Quote";
$quote[3] = "Quote";
$quote[4] = "Quote";
$quote[5] = "Quote";
$quote[6] = "Quote";
$quote[7] = "Quote";
$quote[8] = "Long\r\n quote";
$quote[9] = "Long\r\n quote ";
$quote[10] = "Quote";
$quote[11] = "Very\r\n long\r\n quote";
$quote[12] = "Very\r\n long\r\n quote";
$quote[13] = "You get the idea";
ImageString($im, 3, 100, 0, "$quote[$usedquote]", $white);
header("Content-Type: image/png");
Imagepng($im,'',100);
ImageDestroy ($im);
?>
Result can be seen here .
What can I do to split the long quotes to appear on two lines or more so the whole thing shows?