0

I'm creating an image using PHP GD using imagettftext(). I need, dynamically, determine the font size according to the image's width and height to keep a short text (it is Captcha code) in the visible area of the image.

I tried to examine the information in this page: http://www.pearsonified.com/2011/12/golden-ratio-typography.php but I could not find what I need.

SaidbakR
  • 13,303
  • 20
  • 101
  • 195
  • Maybe a duplicate of http://stackoverflow.com/a/10689312/1652031 – TiMESPLiNTER Sep 18 '14 at 14:17
  • possible duplicate of [imagettftext(): calculate font size to ensure text fits image width](http://stackoverflow.com/questions/10689225/imagettftext-calculate-font-size-to-ensure-text-fits-image-width) – TiMESPLiNTER Sep 18 '14 at 14:17

0 Answers0