X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Flibs%2Fholiday_functions.php;h=61ce6ab20470f0e7bb54218fd44d28eebe3deb94;hb=dfaa8c1675da4071ea451406a6f6fedd4c568416;hp=f013ebeb2188fe5ebe34fa5350c18de0c516f2f5;hpb=43885129ac24cee5545a8a5ad51e90aa182fdf46;p=mailer.git diff --git a/inc/libs/holiday_functions.php b/inc/libs/holiday_functions.php index f013ebeb21..61ce6ab204 100644 --- a/inc/libs/holiday_functions.php +++ b/inc/libs/holiday_functions.php @@ -32,18 +32,18 @@ ************************************************************************/ // Some security stuff... -if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) -{ +if (!defined('__SECURITY')) { $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php"; require($INC); } + // function HOLIDAY_STOP_HOLIDAYS() { // Let's find some expired holiday requests... $result_stop = SQL_QUERY("SELECT userid, holiday_start, holiday_end, comments FROM "._MYSQL_PREFIX."_user_holidays -WHERE holiday_end <= ".time()." +WHERE holiday_end <= UNIX_TIMESTAMP() ORDER BY userid", __FILE__, __LINE__); if (SQL_NUMROWS($result_stop) > 0) {