Question

I need to run a specific url on my domain

http://domain.com/?action=update_feed

, so I made a cron-file.php file, which contains the below code:

<?php
header("Location: http://domain.com/?action=update_feed"); /* Redirect browser */
exit;
?>

In Cpanel's cron manager, i added this to run each minute:

php -q /home/public_html/domain/wp-content/themes/theme/cron-file.php

However, nothing is happening. I also tried using wget instead of php but get the same results.

Was it helpful?

Solution

You can directly access you site without cron-file.php

    wget -qO /dev/null 'http://domain.com/?action=update_feed'
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top