Results 1 to 5 of 5

Thread: PHP Cron Job

  1. #1

    PHP Cron Job

    I have this setup on CPanel

    php -q /home/host/public_html/clients/admin/cron.php

    but I get this:
    sh: -t: command not found
    sh: -t: command not found
    sh: -t: command not found
    sh: -t: command not found

    Ideas?

  2. #2
    Join Date
    Mar 2009
    Location
    Gods Own Country
    Posts
    681
    what happens when you run the command from command line?

  3. #3
    Join Date
    Feb 2004
    Location
    UK
    Posts
    1,431
    Hi

    When running from the cron, you often need to supply the full path for PHP

    /usr/bin/php ....

    Hope that helps.

    Thanks

  4. #4
    Join Date
    Apr 2006
    Location
    Williston Florida
    Posts
    262
    Here is a tutorial on the subject. Depends on how php is set up as to how you call the script:

    http://htmlcenter.com/blog/running-p...pts-with-cron/
    WarPigW2-Old site for game I used to play, and other things along the way
    TutorialMasters - Tutorials Designed for You


  5. #5
    Using the full length method seemed to work. how do I link php to the new php binary?

Posting Permissions

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