Scheduled notifications require a bit of additional configuration with your server cron scheduler. The command that has to be added can be found on the “Notifications” page when a notification that requires scheduling is active. You can recognize these notifications by the clock icon next to the notification name. Copy the command and paste it into the cron file. The command can look like this:
GET ‘https://yourdomain.com/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send’ > /dev/null
You can see the more detailed tutorial on how to set up cron jobs on this link.
If you are not familiar with this, you can use the plugin WP Crontrol for creating a cronjob.
First, go to Amelia/Notifications, and click on one of the scheduled notifications. For example “Appointment Next Day Reminder”. Below that email template, you will see an info block, that shows what needs to be entered into your server, to configure the cron event. For the WP Crontrol plugin, you only need to copy the URL, without “*/15****”.
Then, go to Tools -> Cron Events admin panel, and click on the “Cron Schedules” tab. In it, add a 15-minute interval.
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:
You don’t need to provide the PHP opening tag (<?php).
Please replace “https://yourwebsite.com” with your real web address.
Set the Event name, and set the next run to be “At”, and a few minutes in the future. Select the recurrence (the event you created as the first step, in WP Crontrol – the “every_15_minutes” interval) and that’s it.
If you have any further questions or issues, please feel free to open a new ticket, and we'll gladly help.
Unfortunately, I have no experience with Cron Events, so apologies if I am not understanding properly.
I used WP Crontrol and created the cronjob and the cronevent as you described.
I couldn't see how it helps me or what I need to do to achieve my desired result.
At the moment, when I set up an 'appointment follow up' email notification, I only have the option of sending the email between 30min and 24hrs after the appointment.
I would like to be able to send the email either 1 week or 2 weeks after the appointment.
I wasn't clear how your instructions might allow me to do this.
Depending on the server, there are different configurations for it, which you can contact your hosting provider about, or you can check out one of the solutions for it on this link.
WP Crontrol plugin is the best option if you're not familiar with cron jobs.
So, if you already read that, and still need some clarification here's some further info.
You copy only the URL from below a scheduled notification:
Then, go to Tools/Cron Events, and click on the "Cron Schedules" tab. In it, add a 15-minute interval:
Then 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("yourURL");
Below it add the name and set it to run a few minutes in the future, using the provided time format. So, if you're adding the cron event at 12:45 (local, current time), set it to run at 12:50; and then select the schedule you previously selected:
Click on Add Event, and that's it.
The cron runs every 15 minutes and checks if there's an email to be sent. So, in Amelia Notifications, your scheduled notifications are set to run every day at a certain time. If you set that time to be 15:00 (for example), the emails will be sent when the cron runs after that time.
For example, there's an appointment booked for tomorrow, and it's currently 14:44 - the cron runs, but since it's not yet 15:00, it doesn't send anything. It runs again after 15 minutes, so at 14:59, but there are still no emails flagged by Amelia, so it doesn't send anything. Then it runs again at 15:14 and it sees there's an email that should've been sent at 15:00, so it sends the email. It will only send emails when Amelia sees an appointment scheduled for the next day.
I hope that helps.
Unfortunately, current support does not cover setting up cron, since this can be various for different servers and hosting providers, so, unfortunately, I am not able to help you further with that, so if you can not set up cron yourself, please reach out to your hosting provider, they should help you with this.
If you have any further questions or issues, please feel free to open a new ticket, and we'll gladly help.
I want to be able to send a follow up reminder that is generated more than 1 day after an appointment. Ideally 1 week after the appointment.
Is this possible?
Hello Josh,
Thank you for reaching out to us.
Scheduled notifications require a bit of additional configuration with your server cron scheduler. The command that has to be added can be found on the “Notifications” page when a notification that requires scheduling is active. You can recognize these notifications by the clock icon next to the notification name. Copy the command and paste it into the cron file. The command can look like this:
*/15 * * * * https://yourwebsite.com/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send
If that doesn’t work, please try these as well:
*/15 * * * * wget -q -O – “https://www.yourwebsite.com/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send”
*/15 * * * * /usr/local/bin/php ~/public_html/wp-cron.php –action=’wpamelia_api’ –call=’/notifications/scheduled/send’
GET ‘https://yourdomain.com/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send’ > /dev/null
You can see the more detailed tutorial on how to set up cron jobs on this link.
If you are not familiar with this, you can use the plugin WP Crontrol for creating a cronjob.
First, go to Amelia/Notifications, and click on one of the scheduled notifications. For example “Appointment Next Day Reminder”. Below that email template, you will see an info block, that shows what needs to be entered into your server, to configure the cron event. For the WP Crontrol plugin, you only need to copy the URL, without “*/15****”.
Then, go to Tools -> Cron Events admin panel, and click on the “Cron Schedules” tab. In it, add a 15-minute interval.
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://yourwebsite.com/wp-admin/admin-ajax.php?action=wpamelia_api&call=/notifications/scheduled/send”);
You don’t need to provide the PHP opening tag (<?php).
Please replace “https://yourwebsite.com” with your real web address.
Set the Event name, and set the next run to be “At”, and a few minutes in the future. Select the recurrence (the event you created as the first step, in WP Crontrol – the “every_15_minutes” interval) and that’s it.
If you have any further questions or issues, please feel free to open a new ticket, and we'll gladly help.
Have a nice day!
Kind Regards,
Stanislav Snagovskiy
[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
You can try wpDataTables add-ons before purchase on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables
Stanislav, thank you for your very prompt reply.
Unfortunately, I have no experience with Cron Events, so apologies if I am not understanding properly.
I used WP Crontrol and created the cronjob and the cronevent as you described.
I couldn't see how it helps me or what I need to do to achieve my desired result.
At the moment, when I set up an 'appointment follow up' email notification, I only have the option of sending the email between 30min and 24hrs after the appointment.
I would like to be able to send the email either 1 week or 2 weeks after the appointment.
I wasn't clear how your instructions might allow me to do this.
Thanks
Dear Josh,
You are welcome,
Depending on the server, there are different configurations for it, which you can contact your hosting provider about, or you can check out one of the solutions for it on this link.
WP Crontrol plugin is the best option if you're not familiar with cron jobs.
So, if you already read that, and still need some clarification here's some further info.
You copy only the URL from below a scheduled notification:
Then, go to Tools/Cron Events, and click on the "Cron Schedules" tab. In it, add a 15-minute interval:
Then 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:
Below it add the name and set it to run a few minutes in the future, using the provided time format. So, if you're adding the cron event at 12:45 (local, current time), set it to run at 12:50; and then select the schedule you previously selected:
Click on Add Event, and that's it.
The cron runs every 15 minutes and checks if there's an email to be sent. So, in Amelia Notifications, your scheduled notifications are set to run every day at a certain time. If you set that time to be 15:00 (for example), the emails will be sent when the cron runs after that time.
For example, there's an appointment booked for tomorrow, and it's currently 14:44 - the cron runs, but since it's not yet 15:00, it doesn't send anything. It runs again after 15 minutes, so at 14:59, but there are still no emails flagged by Amelia, so it doesn't send anything. Then it runs again at 15:14 and it sees there's an email that should've been sent at 15:00, so it sends the email. It will only send emails when Amelia sees an appointment scheduled for the next day.
I hope that helps.
Unfortunately, current support does not cover setting up cron, since this can be various for different servers and hosting providers, so, unfortunately, I am not able to help you further with that, so if you can not set up cron yourself, please reach out to your hosting provider, they should help you with this.
If you have any further questions or issues, please feel free to open a new ticket, and we'll gladly help.
Have a nice day!
Kind Regards,
Stanislav Snagovskiy
[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
You can try wpDataTables add-ons before purchase on these sandbox sites:
Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables