Setup script bootstrapped with new theme selector - Take 2 (#2139)
[openemr.git] / library / ajax / turnoff_birthday_alert.php
blobea6b56d3060f8ad8f3ba2226d24e980276bf16dd
1 <?php
2 /**
3 * Turn off/on Birthday alert .
5 * @package OpenEMR
6 * @link http://www.open-emr.org
7 * @author Sharon Cohen <sharonco@matrix.co.il>
8 * @author Brady Miller <brady.g.miller@gmail.com>
9 * @copyright Copyright (c) 2017 Sharon Cohen <sharonco@matrix.co.il>
10 * @copyright Copyright (c) 2017-2018 Brady Miller <brady.g.miller@gmail.com>
11 * @license https://github.com/openemr/openemr/blob/master/LICENSE GNU General Public License 3
14 require_once(dirname(__FILE__) . "/../../interface/globals.php");
16 use OpenEMR\Reminder\BirthdayReminder;
18 if (!verifyCsrfToken($_POST["csrf_token_form"])) {
19 csrfNotVerified();
22 if (!empty($_POST['pid']) && !empty($_POST['user_id'])) {
23 $birthdayReminder = new BirthdayReminder($_POST['pid'], $_POST['user_id']);
24 $birthdayReminder->birthdayAlertResponse($_POST['turnOff']);