r.php 782 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. /**
  3. * Copyright (c) UNA, Inc - https://una.io
  4. * MIT License - https://opensource.org/licenses/MIT
  5. *
  6. * @defgroup UnaCore UNA Core
  7. * @{
  8. */
  9. require_once('./inc/header.inc.php');
  10. require_once(BX_DIRECTORY_PATH_INC . "design.inc.php");
  11. bx_import('BxDolLanguages');
  12. check_logged();
  13. $sRequest = ltrim($_GET['_q'], '/');
  14. $sPath = parse_url(BX_DOL_URL_ROOT, PHP_URL_PATH);
  15. if ($sPath && '/' != $sPath)
  16. $sRequest = bx_ltrim_str($sRequest, rtrim($sPath, '/'));
  17. $aRewriteRules = BxDolRewriteRulesQuery::getActiveRules();
  18. foreach ($aRewriteRules as $a) {
  19. if (preg_match('#'.$a['preg'].'#i', $sRequest, $aMatches)) {
  20. BxDolService::callSerialized($a['service'], $aMatches);
  21. exit;
  22. }
  23. }
  24. BxDolTemplate::getInstance()->displayPageNotFound();
  25. /** @} */