within my wordpress website www.lynnbeeldschoon.be I am trying to setup the cron job to have the scheduled notifications being send out correctly. On the support page from Amelia I could found some technical information about it however I don't succeed in getting it created. I am not able to perform this step with using WP Crontrol:
Now go back to the “Cron Events” tab, and click on “Add New”.
Below it, select the “PHP Cron event” radio button, and add the URL you copied from Amelia/Notifications in this form:
We can confirm that the process is still the same for WP Crontrol,
It seems that you simply don't see the "PHP Event" radio option while making a new Cron Event in WP Crontrol.
Here is how it should look, a screenshot from our testing environment when adding a new Cron job:
Please take a look at this official WP Crontrol Page, in the FAQ section, find this question "which users can manage PHP cron events".
They mention a possible reason why users can't see the "PHP Event" radio button (the user you're logged in to WordPress with most likely doesn't have the edit_files capability).
Crons are scheduled tasks of the server, and this is a 3rd party plugin, so it is not an issue coming from Amelia.
Please make sure you have the latest WP Crontrol version installed and go through the steps explained in their FAQ section, which is mentioned above.
Also, there's a possibility that a security plugin disallows file editing, which as a result hid that "PHP cron event" option selection in WP Crontrol. In iThemes Security there's a "Disable File Editor" option in settings, and that needs to be turned off as well. If you're using a different security plugin, look for a similar option, or reach out to that plugin's support team.
thanks for your answer. I was able to enable the PHP cron event option. However when adding the exact line in the PHP box, I have received an error message once I go to the overview of the cron events. Please refer to screenshots in attachment.
I found the solution. I had to use the file_get_contents statement. There was still a syntax error but I could find as well that issue. It was an issue with the quotes. I did a copy paste of the exact text and those quotes where not recognised as PHP so replacing them solved the issue:
Hi,
within my wordpress website www.lynnbeeldschoon.be I am trying to setup the cron job to have the scheduled notifications being send out correctly. On the support page from Amelia I could found some technical information about it however I don't succeed in getting it created. I am not able to perform this step with using WP Crontrol:
Now go back to the “Cron Events” tab, and click on “Add New”.
Below it, select the “PHP Cron event” radio button, and add the URL you copied from Amelia/Notifications in this form:
file_get_contents(“https://lynnbeeldschoon.be/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send”);
There is no option to select PHP Cron Event and so I am not able to add the url copied in as described.
Is there any other alternative to get this cron job set up?
Thanks in advance for your help.
Kind Regards,
Andy
Attached files: Screenshot 2024-04-02 at 21.30.40.png
Hello andy,
Thank you for reaching out to us.
We can confirm that the process is still the same for WP Crontrol,
It seems that you simply don't see the "PHP Event" radio option while making a new Cron Event in WP Crontrol.
Here is how it should look, a screenshot from our testing environment when adding a new Cron job:
Please take a look at this official WP Crontrol Page, in the FAQ section, find this question "which users can manage PHP cron events".
They mention a possible reason why users can't see the "PHP Event" radio button (the user you're logged in to WordPress with most likely doesn't have the edit_files capability).
Crons are scheduled tasks of the server, and this is a 3rd party plugin, so it is not an issue coming from Amelia.
Please make sure you have the latest WP Crontrol version installed and go through the steps explained in their FAQ section, which is mentioned above.
Also, there's a possibility that a security plugin disallows file editing, which as a result hid that "PHP cron event" option selection in WP Crontrol. In iThemes Security there's a "Disable File Editor" option in settings, and that needs to be turned off as well. If you're using a different security plugin, look for a similar option, or reach out to that plugin's support team.
SiteGround Optimizer -> Frontend Optimization -> Javascript -> Defer Render-blocking JavaScript (uncheck)
Kind Regards,
Uros Jovanovic
[email protected]
Rate my support
wpDataTables: FAQ | Facebook | Twitter | Instagram | Front-end and back-end demo | Docs
Amelia: FAQ | Facebook | Twitter | Instagram | Amelia demo sites | Docs | Discord Community
You can try wpDataTables add-ons before purchasing on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables
Hi Uros,
thanks for your answer. I was able to enable the PHP cron event option. However when adding the exact line in the PHP box, I have received an error message once I go to the overview of the cron events. Please refer to screenshots in attachment.
I have added this line:
*/15 * * * * https://www.lynnbeeldschoon.be/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send
Do I need to change it to something else? Maybe just like this?
https://www.lynnbeeldschoon.be/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send
Thanks for your help!
Kind regards
Andy
Attached files: Screenshot 2024-04-16 at 20.31.53.png
Screenshot 2024-04-16 at 20.29.38.png
Hi Uros,
I found the solution. I had to use the file_get_contents statement. There was still a syntax error but I could find as well that issue. It was an issue with the quotes. I did a copy paste of the exact text and those quotes where not recognised as PHP so replacing them solved the issue:
file_get_contents("https://lynnbeeldschoon.be/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send");
Just wanted to update you on the root cause and the solution for further purpose in case other customers should report issues with it.
Thanks for your support anyhow!
Have a nice evening
kind regards,
Andy
Hello Andy,
Thank you very much for sharing this with me and I am glad to hear that the issue has been resolved.
I will have this ticket closed now.
Kind Regards,
Uros Jovanovic
[email protected]
Rate my support
wpDataTables: FAQ | Facebook | Twitter | Instagram | Front-end and back-end demo | Docs
Amelia: FAQ | Facebook | Twitter | Instagram | Amelia demo sites | Docs | Discord Community
You can try wpDataTables add-ons before purchasing on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables