Results 1 to 4 of 4

Thread: Problem with ImageGD,

  1. #1
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default Problem with ImageGD,

    Hello!

    I'm having a problem with my ImageGD library I created a while ago, it doesn't work when I try on my localhost, but it works when I do it online.

    You can view my code here.

    Thanks for any help given!
    Last edited by Nile; 04-12-2009 at 09:28 PM.
    Jeremy | jfein.net

  2. #2
    Join Date
    Jul 2008
    Posts
    199
    Thanks
    6
    Thanked 58 Times in 57 Posts

    Default

    I'm guessing you have WAMP. If you comment out the header function, you'll see it's spitting out the following errors:
    Code:
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    
    Notice: Array to string conversion in C:\wamp\www\gd.php on line 137
    That should help you fix your code up.

  3. #3
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    It didn't really help, I tried changing:
    PHP Code:
    if(strlen($color) == || strlen($color) == && substr($color01) == "#"){ 
    To:
    PHP Code:
    if(is_string($color) && strlen($color) == || strlen($color) == && substr($color01) == "#"){ 
    But it still gives me the same error. Yes, I am using Wamp.
    Jeremy | jfein.net

  4. #4
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    No body can help me?
    Edit:
    Solution:
    PHP Code:
    if((strlen((string)$color) == || strlen((string)$color) == 4) && substr((string)$color01) == "#"){ 
    Last edited by Nile; 04-12-2009 at 09:28 PM.
    Jeremy | jfein.net

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
  •