Dynamic Images

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Eric

    Dynamic Images

    I am trying to make a script that writes text onto a small image. How would
    I make the image expand (wider) if longer text is inputed?

    Please email the solution to emb1992@gmail.c om as I might not check back
    here.


  • Daniel Tryba

    #2
    Re: Dynamic Images

    Eric <emb1992@gmail. com> wrote:[color=blue]
    > I am trying to make a script that writes text onto a small image. How would
    > I make the image expand (wider) if longer text is inputed?[/color]

    Assuming you are using ttf: imagettfbbox

    This will give you the bounding box for the string, if larger that
    current image resource: imagecopyresamp led/imagecopyresizd
    [color=blue]
    > Please email the solution to emb1992@gmail.c om as I might not check back
    > here.[/color]

    Why should I just send a solution to you and withold that from the
    community here? Posting here === reading here!

    Comment

    • Alan Little

      #3
      Re: Dynamic Images

      Carved in mystic runes upon the very living rock, the last words of Eric
      of comp.lang.php make plain:
      [color=blue]
      > Please email the solution to emb1992@gmail.c om as I might not check
      > back here.[/color]

      Please email your question to ImTooLazy.DoAll MyWorkForMe@buz zoff.com as I
      might not bother to read it here.

      --
      Alan Little
      Phorm PHP Form Processor

      Comment

      Working...