We use an image and write some text when we run that code it will write text on that image where ever you want to add in the image X and Y coordinates required.
<?php
header ("Content-type: image/jpeg");
$string = "This is Softarea.in";
$font = 4;
$width = imagefontwidth($font) * strlen($string) ;
$height = imagefontheight($font) ;
$im = imagecreatefromjpeg("test.jpg");
$x = imagesx($im) - $width ;
$y = imagesy($im) - $height;
$backgroundColor = imagecolorallocate ($im, 255, 255, 255);
$textColor = imagecolorallocate ($im, 0, 0,0);
imagestring ($im, $font, $x, $y, $string, $textColor);
imagejpeg($im);
?>
As I always here, if you get into troubles, you can use the comment form or Our Facebook Page !
0 comments
Post a Comment
Thanks For Visit :)
Note: only a member of this blog may post a comment.