Reminder Module features added:
[openemr.git] / library / ajax / dated_reminders_counter.php
blob4357f00d76479d92902c4b7a89d82c6233595ac5
1 <?php
2 // ------------------------------------------------------------------------ //
3 // OpenEMR Electronic Medical Records System //
4 // Copyright (c) 2012 tajemo.co.za //
5 // <http://www.tajemo.co.za/> //
6 // ------------------------------------------------------------------------ //
7 // This program is free software; you can redistribute it and/or modify //
8 // it under the terms of the GNU General Public License as published by //
9 // the Free Software Foundation; either version 2 of the License, or //
10 // (at your option) any later version. //
11 // //
12 // You may not change or alter any portion of this comment or credits //
13 // of supporting developers from this source code or any supporting //
14 // source code which is considered copyrighted (c) material of the //
15 // original comment or credit authors. //
16 // //
17 // This program is distributed in the hope that it will be useful, //
18 // but WITHOUT ANY WARRANTY; without even the implied warranty of //
19 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
20 // GNU General Public License for more details. //
21 // //
22 // You should have received a copy of the GNU General Public License //
23 // along with this program; if not, write to the Free Software //
24 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA //
25 // --------------------------------------------------------------------------//
26 // Original Author of this file: Craig Bezuidenhout (Tajemo Enterprises) //
27 // Purpose of this file: Returns a count of due messages for current user //
28 // --------------------------------------------------------------------------//
30 //SANITIZE ALL ESCAPES
31 $sanitize_all_escapes=true;
34 //STOP FAKE REGISTER GLOBALS
35 $fake_register_globals=false;
37 require_once("../../interface/globals.php");
38 require_once("$srcdir/htmlspecialchars.inc.php");
39 require_once("$srcdir/dated_reminders.php");
41 $dueReminders = GetDueReminderCount(5,strtotime(date('Y/m/d')));
42 echo ($dueReminders > 0 ? '('.text(intval($dueReminders)).')' : '');