3 if (!defined( "PLOG_CLASS_PATH" )) {
4 define( "PLOG_CLASS_PATH", dirname(__FILE__)."/");
7 include_once( PLOG_CLASS_PATH."class/bootstrap.php" );
8 lt_include( PLOG_CLASS_PATH."class/config/config.class.php" );
9 lt_include( PLOG_CLASS_PATH."class/net/http/httpvars.class.php" );
10 lt_include( PLOG_CLASS_PATH."class/net/customurlhandler.class.php" );
11 lt_include( PLOG_CLASS_PATH."class/net/request.class.php" );
12 lt_include( PLOG_CLASS_PATH."class/net/requestgenerator.class.php" );
14 // get the configuration data
15 $config =& Config::getConfig();
17 // in order to maintain compatibility with previous version, and the alternative
18 // format of search-engine friendly urls
19 if( $config->getValue( "request_format_mode" ) == SEARCH_ENGINE_FRIENDLY_MODE ) {
20 lt_include( PLOG_CLASS_PATH."error.php" );
24 $server = HttpVars::getServer();
25 $requestParser = new CustomUrlHandler();
26 $error = $requestParser->process($server["REQUEST_URI"]);
27 $vars = $requestParser->getVars();
28 $params = $requestParser->getParams();
29 $includeFile = $requestParser->getIncludeFile();
31 // Hack to force an error page in defaultaction
33 $vars["userId"] = "userId";
34 $params["userId"] = "INVALID";
38 // fill in the request with the parameters we need
41 foreach( $vars as $key => $value ) {
42 if( is_array( $params ) && array_key_exists( $key, $params ) && $params["$key"] != "" )
43 HttpVars::setRequestValue( $vars["$key"], $params["$key"] );
46 // and transfer execution to the main script
47 lt_include( PLOG_CLASS_PATH.$includeFile );