[phpBB Debug] PHP Warning: in file [ROOT]/includes/crs/crs_misc_functions.php on line 37: mime_content_type(): Empty filename or path
[phpBB Debug] PHP Warning: in file [ROOT]/includes/crs/crs_misc_functions.php on line 37: mime_content_type(): Empty filename or path
Zen Cart 源代码 init_special_funcs.php

Zen Cart 源代码 init_special_funcs.php




下载文件

文件名: init_special_funcs.php
文件类型: PHP文件
文件大小: 2.18 KiB
MD5: eb9682f61c4b5379a71a7149d856e423

init_special_funcs.php - 关闭高亮
  1. <?php
  2. /**
  3.  * load the system wide functions
  4.  * see {@link  http://www.zen-cart.com/wiki/index.php/Developers_API_Tutorials#InitSystem wikitutorials} for more details.
  5.  *
  6.  * @package initSystem
  7.  * @copyright Copyright 2003-2007 Zen Cart Development Team
  8.  * @copyright Portions Copyright 2003 osCommerce
  9.  * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
  10.  * @version $Id: init_special_funcs.php 5924 2007-02-28 08:25:15Z drbyte $
  11.  */
  12. if (!defined('IS_ADMIN_FLAG')) {
  13.   die('Illegal Access');
  14. }
  15. /**
  16.  * require the whos online functions and update
  17.  */
  18. require(DIR_WS_FUNCTIONS . 'whos_online.php');
  19. zen_update_whos_online();
  20. /**
  21.  * require the password crypto functions
  22.  */
  23. require(DIR_WS_FUNCTIONS . 'password_funcs.php');
  24. /**
  25.  * require the banner functions, auto-activate and auto-expire
  26.  */
  27. require(DIR_WS_FUNCTIONS . 'banner.php');
  28. zen_activate_banners();
  29. zen_expire_banners();
  30. /**
  31.  * only process once per session do not include banners as banners expire per click as well as per date
  32.  * require the banner functions, auto-activate and auto-expire.
  33.  *
  34.  * this is processed in the admin for dates that expire while being worked on
  35.  */
  36. // check if a reset on one time sessions settings should occur due to the midnight hour happening
  37.   if (!isset($_SESSION['today_is'])) {
  38.     $_SESSION['today_is'] = date('Y-m-d');
  39.   }
  40.   if ($_SESSION['today_is'] != date('Y-m-d')) {
  41.     $_SESSION['today_is'] = date('Y-m-d');
  42.     $_SESSION['updateExpirations'] = false;
  43.   }
  44. if (!isset($_SESSION['updateExpirations']) || $_SESSION['updateExpirations'] !== true) {
  45.   /**
  46.    * require the specials products functions, auto-activate and auto-expire
  47.    */
  48.   require(DIR_WS_FUNCTIONS . 'specials.php');
  49.   zen_start_specials();
  50.   zen_expire_specials();
  51.   /**
  52.    * require the featured products functions, auto-activate and auto-expire
  53.    */
  54.   require(DIR_WS_FUNCTIONS . 'featured.php');
  55.   zen_start_featured();
  56.   zen_expire_featured();
  57.   /**
  58.    * require the salemaker functions, auto-activate and auto-expire
  59.    */
  60.   require(DIR_WS_FUNCTIONS . 'salemaker.php');
  61.   zen_start_salemaker();
  62.   zen_expire_salemaker();
  63.  
  64.   $_SESSION['updateExpirations'] = true;
  65. }
  66. ?>