entry.ctrl.php 790 B

123456789101112131415161718192021222324252627282930
  1. <?php
  2. /**
  3. * [WeEngine System] Copyright (c) 2014 WE7.CC
  4. * WeEngine is NOT a free software, it under the license terms, visited http://www.we7.cc/ for more details.
  5. */
  6. defined('IN_IA') or exit('Access Denied');
  7. load()->func('cron');
  8. $id = intval($_GPC['id']);
  9. $cron = cron_check($id);
  10. if(is_error($cron)) {
  11. message($cron, '', 'ajax');
  12. }
  13. $_W['uniacid'] = $cron['uniacid'];
  14. $_W['uniaccount'] = $_W['account'] = uni_fetch($_W['uniacid']);
  15. $_W['acid'] = $_W['account']['acid'];
  16. $_W['weid'] = $_W['uniacid'];
  17. $_W['cron'] = $cron;
  18. $moduleCron = WeUtility::createModuleCron($cron['module']);
  19. if(!is_error($moduleCron)) {
  20. define('IN_MODULE', $cron['module']);
  21. $method = 'doCron' . ucfirst($cron['filename']);
  22. $moduleCron->$method();
  23. exit();
  24. } else {
  25. message($moduleCron, '', 'ajax');
  26. }