index.php 938 B

123456789101112131415161718192021222324252627282930
  1. <?php
  2. declare(strict_types=0);
  3. /**
  4. * 队列
  5. *
  6. *
  7. * by abc www.abc.com 二次开发修正版本
  8. */
  9. define('APP_ID', 'queue');
  10. defined('BASE_ROOT_PATH') or define('BASE_ROOT_PATH',str_replace('/queue','',dirname(__FILE__)));
  11. defined('BASE_PATH') or define('BASE_PATH',BASE_ROOT_PATH . '/queue');
  12. if (!@include(dirname(dirname(__FILE__)) . '/global.php')) exit('global.php isn\'t exists!');
  13. if (!@include(BASE_CORE_PATH . '/lrlz.php')) exit('lrlz.php isn\'t exists!');
  14. require_once(BASE_ROOT_PATH . '/fooder.php');
  15. require_once(BASE_ROOT_PATH . '/helper/event_looper.php');
  16. if (empty($_SERVER['argv'][1]) || empty($_SERVER['argv'][2])) exit('parameter error');
  17. $_GET['act'] = $_SERVER['argv'][1];
  18. $_GET['op'] = $_SERVER['argv'][2];
  19. if (!@include(BASE_PATH . '/control/control.php')) exit('control.php isn\'t exists!');
  20. function work_proc() {
  21. Base::run();
  22. }
  23. event\util::fork_worker('work_proc',0);