initialization()){ if ($_SERVER["REQUEST_METHOD"] == "GET" || $_SERVER["REQUEST_METHOD"] == "POST") { if (isset($_GET['url']) || isset($_POST['url'])) { $yihuapost->saveVisitor(); if(isset($_GET['url'])) { $request = $_GET['url']; } else{ $request = $_POST['url']; } include_once ("./system_files/language.php"); $siteProfile = new YihuaPostProfile($siteLanguage,$yihuapost->getCurrentDB()); if(empty($request)) { $checkRewrite = true; require("pages/home.php"); } else{ $urlArray = (explode("/",$request)); if(count($urlArray) > 0) { $model = $yihuapost->getRewriteUrlModel($urlArray[0]); if(count($urlArray) <= $yihuapost->getRewriteSize()) { if($model) { $checkRewrite = true; require("pages/".$model.".php"); } } } } if(!$checkRewrite) { require ("pages/404.php"); } } else { require("pages/home.php"); } } }else{ require("config/install.php"); }