• Resolved freemason

    (@freemason)


    Hi,

    I am trying to move Newsletter task scheduler (cron) to server side. For that, I tryed to setup a Cron via CPanel with the following: */15 * * * * php /home/XXXXXXX/public_html/wp-content/plugins/mailpoet/mailpoet-cron.php /home/XXXXXXX/public_html/ (XXXXXX being my hostname).

    However, everytime the Cron runs, I get the error message “You need to pass a WordPress root as an argument.”. My host provider is a2hosting.

    Can you help me solving this?

    Thanks
    A Jorge

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi there @freemason,

    Thanks for reaching out!

    You might need to add your path before the php, for example /usr/local/bin/php.

    Your path to the PHP executable can be found in your cPanel > Advanced > Cron Jobs. You can also reach out to your hosting provider to get the WordPress root path and correct it in your command.

    Hope it helps, please let us know if you need further assistance!

    Thread Starter freemason

    (@freemason)

    Hi Elvira,

    You solved it. Thanks for your help.

    Regards
    Antonio Jorge

    Hi there @freemason,

    Thanks for getting back to us!

    I’m glad to hear it’s resolved now 🙂

    Let us know if you need further help!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Cron Job Error’ is closed to new replies.