View Full Version : Right to Left ImageString?

08-24-2009, 05:39 AM
Hmm, is it possible to format wording from right to left?

I want to have a ID displayed in the upper right hand of a image, but obviously, don't want it to get so big it runs out of it's container, or off the image.

08-24-2009, 11:25 AM
If you're using TFFs you can use imagettfbox (http://uk3.php.net/manual/en/function.imagettfbbox.php) to get the positions of the corners, from that you can find out the width of the text. Using that, you can enter the x position of the text as the image width minus the width of the text.