-
SitePoint Zealot

Cron Job
Hello,
I'm trying to set up a cron job using Plesk but I'm having trouble getting it to work.
I think the problem is in stating the path to PHP and the path to the script, does anyone know how I'd find out what the paths are?
Cheers,
Jon
-
In cPanel => /usr/local/bin/php -f path-to-your-php-file.php
in Plesk => /usr/bin/php -f path-to-your-php-file.php
You can also directly use wget URL-to-your-php-file.php
-
SitePoint Wizard
try from a shell which php to find the path to the interpreter
the path to the actual script, put this in it and run through web browser
PHP Code:
<?php
echo __FILE__;
Be aware, relative filepaths don't behave the same when you run php via the command line. It may use a seperate php.ini file as well.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks