Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Regular Coder Zangeel's Avatar
    Join Date
    Oct 2007
    Location
    public_html/
    Posts
    638
    Thanks
    17
    Thanked 79 Times in 79 Posts

    Exclamation Image contains errors??

    Hello,

    I'm trying to load a PNG image I have as a signature with dynamic text on it. However, when I try to load it, it says The image "xxxxxxxxxxx" cannot be displayed because it contains errors", so I tried a different image and it gives me the same error. Here's the script im using

    PHP Code:
    <?php
    header
    ("Content-Type: image/png");

    $im imagecreatefrompng("sig.png");

    if (!
    $im)
    {
        die (
    'Error');
    }

    $sText imagecolorallocate($im255,255,255);

    imagestring($im101010"Testing"$sText);

    imagepng($im);

    imagedestroy($im);

    ?>
    Last edited by Zangeel; 06-19-2010 at 06:35 AM.
    PHP Code:
    $aString is_string((string)array()) ? true false// true :D 
    [/CENTER]

  • #2
    Regular Coder Zangeel's Avatar
    Join Date
    Oct 2007
    Location
    public_html/
    Posts
    638
    Thanks
    17
    Thanked 79 Times in 79 Posts
    Woops ^^ just moved the header down to above the imagepng function silly mistake!
    PHP Code:
    $aString is_string((string)array()) ? true false// true :D 
    [/CENTER]


  •  

    Posting Permissions

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