- Member | 7
So I have this problem. I generated an image without a problem so I tried to write something on it. In this case – I'm trying to write “ABC” on it but somehow it generates only squares. This is code:
$img = Image::fromFile($this->context->parameters['wwwDir'].'/images/banner2.png'); $img->alphaBlending(false); $img->saveAlpha(true); $img->ttfText(19, 0, 70, 48,Array('red'=>255,'blue'=>255,'green'=>255, 'alpha'=> 0),$this->context->parameters['wwwDir'].'/images/VNARIAL.TTF','ABC'); $img->send(Image::PNG);
and ouput: http://www.nahrejto.cz/…c4e8f0dc.png
Can I ask where the problem actually is?
EDIT: I fixed it
Last edited by ThomasTheCat (2014-04-23 08:13)