Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Nov 2005
    Thanked 0 Times in 0 Posts

    Exclamation cron job wont run imagecreatefrompng

    So i have a script on my server that creates a set of images from one. When the script is called in the browser the script runs fine. When it runs as a cron job it fails.

    now to see if i am getting an error i ran the script from the command prompt as the same user that is running the cron job. and i get this error

    call to undefined function: imagecreatefrompng()

    but this works in the browser!!! any ideas?

  • #2
    Master Coder
    Join Date
    Jun 2003
    Cottage Grove, Minnesota
    Thanked 1,096 Times in 1,087 Posts
    Specifically, how do you "call" the script?

    If you're using your browser to do something like: makephoto.php?photo=mypic.png

    And you're doing the same thing with the CRON, the method you use
    in your PHP script (to read the variable $photo) may be your problem.



    If you're not sure whether to use POST or GET, use REQUEST ... that
    will handle all incoming variables.


    Posting Permissions

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