So my question is, how do I call my function?
Here is the function that works by itself.
Code: Select all
<?
function createLottoTicket($ticketNumber) {
header ("Content-type: image/pjpeg");
$stringImage = (string)$ticketNumber;
$font = 5;
$im = ImageCreateFromjpeg("./images/lottoTicket.jpg");
$background_color = imagecolorallocate ($im, 255, 255, 255); //white background
$text_color = imagecolorallocate ($im, 0, 0,0);//black text
imagestring ($im, $font, 24, 40, $stringImage, $text_color);
imagejpeg ($im);
}
createLottoTicket(10101);
?>