Results 1 to 2 of 2

Thread: Text > Image (With Fonts)

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Dec 2003
    Posts
    4,787

    Text > Image (With Fonts)

    Hey,

    I need to generate a PNG file from text and there are plenty of examples out there for this, however I need to use a specific font, the font needs to be user selected so they upload the font. From what I can see this will be .ttf or open type.

    Any suggestions?

  2. #2
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Text > Image (With Fonts)

    well you are going to want to use the GDLib.

    what you need is a textarea for the user to put their text (or an upload if you wish), and a upload field for the users font. Something you can also do (instead of having the users upload multiple .ttf fonts, is have a dropdown with all the available fonts that the user can choose from)

    then, once you have uploaded the font somewhere, you will use the gdlib to make the image and use imagettftext to set the font.

    I am not sure if you are familiar with the gdlib... so let me know.
    My usual boring signature: Something

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width