How can I add text to an image?



How can I add text to an image? ..

Answer / jude jeevanraj.p

There is a built in function to add text to an image. The
tricky bit is knowing the parameters.

It is not worth learning these, therefore take note of them
from an existing example or the manual each time that you
need to write text with PHP!

The function used to do this using TrueType fonts is called
imagettftext and take a deep breath as here come the
parameters:

array imagettftext ( resource $image, float $size, float
$angle, int $x, int $y, int $color, string $fontfile,
string $text )

Is This Answer Correct ?    4 Yes 1 No

Post New Answer

More PHP Interview Questions

Explain what are the different errors in php?

0 Answers  


What are sql injections, how do you prevent them and what are the best practices?

0 Answers  


Actually am working in existing project which is developed in .net, am converting the .net into php code. am facing problem after uploading the .php in server. amgetting the error message like "The page cannot be found" but its working perfectly in local host

2 Answers  


What is mean tnq

0 Answers   TNQ,


Explain the types of string comparision function in PHP

0 Answers  






How do you debug php?

0 Answers  


What is super () python?

0 Answers  


What are different types of errors available in Php?

0 Answers  


What is data abstraction in php?

0 Answers  


Does php class need constructor?

0 Answers  


What is the maximum size of a database in mysql?

0 Answers  


CWD is a type of shell variable. State Whether True or False?

0 Answers  


Categories