Changeset 37 for trunk/Global.php


Ignore:
Timestamp:
May 5, 2019, 5:17:06 PM (6 years ago)
Author:
chronos
Message:
  • Modified: Application made using classes System and Application.
  • Modified: Used Common package for better code reuse.
  • Modified: Application made modular. Web sections converted to application modules. They will register pages in main application object.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Global.php

    r31 r37  
    2424 
    2525  return $Config['BaseURL'].$URL;
     26}
     27
     28function ProcessURL()
     29{
     30  if(array_key_exists('REDIRECT_QUERY_STRING', $_SERVER))
     31    $PathString = $_SERVER['REDIRECT_QUERY_STRING'];
     32    else $PathString = '';
     33  if(substr($PathString, -1, 1) == '/') $PathString = substr($PathString, 0, -1);
     34  $PathItems = explode('/', $PathString);
     35  if(array_key_exists('REQUEST_URI', $_SERVER) and (strpos($_SERVER['REQUEST_URI'], '?') !== false))
     36    $_SERVER['QUERY_STRING'] = substr($_SERVER['REQUEST_URI'], strpos($_SERVER['REQUEST_URI'], '?') + 1);
     37    else $_SERVER['QUERY_STRING'] = '';
     38  parse_str($_SERVER['QUERY_STRING'], $_GET);
     39  return($PathItems);
    2640}
    2741
     
    164178  ));
    165179}
     180
     181function GetMicrotime()
     182{
     183  list($Usec, $Sec) = explode(' ', microtime());
     184  return ((float)$Usec + (float)$Sec);
     185}
Note: See TracChangeset for help on using the changeset viewer.