SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Jul 2002
    Location
    Romania
    Posts
    35
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    wbmp outputting directly

    hello
    i am making a wapsite creator site,and i want every site to have their own logo
    i want,that i got the background image,that a text should be displayed on it with a specified font,and to output in directly in wml,without using header(image....,cause header is already set,as wml
    any ideaa?
    please help
    thanks

    edit:
    i got this:
    Header("Content-type: image/jpeg");
    $imagepath = "/home/site/blank.jpg";

    $im = imagecreatefromjpeg($imagepath);
    $tc = imagecolorclosest ($im, 62, 44, 66);
    imagettftext ($im, 15, 10, 150, 280, $tc, "/home/site/annifont.TTF", $text);
    imagejpeg($im,'',100);

    but this uses header,and i want so it should generate an image like this does,and output as <img src=\"$imagevariable\"> + this is jpeg not wbmp
    Last edited by GJoz; Dec 21, 2002 at 10:18.

  2. #2
    SitePoint Evangelist
    Join Date
    Nov 2001
    Location
    UK
    Posts
    466
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I haven't yet dabbled with wbmp, though I'd suggest using one of the available headers anyway

    image/wbmp
    image/wap
    image/vnd

    then just change the create call to

    imagewbmp($im)

    note: the third parameter in an imagewbmp call is NOT for compression (like the jpeg equivalent), it is apparently for the colour index from the associated palette (0-255 as wbmp only has support for 256 colours) .

    Also see http://www.php.net/manual/en/function.imagewbmp.php
    teckis - that's news to me.


Bookmarks

Posting Permissions

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