%PDF- %PDF-
Direktori : /www/varak.net/practiscore.varak.net_old/practiscore.varak.net/www/ |
Current File : //www/varak.net/practiscore.varak.net_old/practiscore.varak.net/www/index.php |
<?php //ob_start(); include "../bootstrap.php"; $action = $_GET['action']; $id = isset($_GET['id']) ? $_GET['id'] : false; $smarty->assign('id', $id); $smarty->assign('isAdmin', $isAdmin); $template = "index.tpl"; switch($action) { case 'index': { include "../app/index.php"; $template = "index.tpl"; break; } case 'import': { $template = "import.tpl"; break; } case 'import-process': { include "../app/import-process.php"; $template = "error.tpl"; break; } case 'do-login': { include "../app/do-login.php"; break; } case 'logout': { include "../app/logout.php"; break; } case 'forgot-password': { $template = "forgot-password.tpl"; break; } case 'do-forgot-password': { $template = "do-forgot-password.tpl"; include "../app/forgot-password.php"; break; } case 'change-password': { $smarty->assign("token", $_GET['token']); $template = "change-password.tpl"; break; } case 'do-change-password': { $template = "do-change-password.tpl"; include "../app/change-password.php"; break; } case 'match-detail': { include "../app/match-detail.php"; $template = "match-detail.tpl"; break; } case 'activate-shooter': { $active = true; include "../app/activate-shooter.php"; break; } case 'deactivate-shooter': { $active = false; include "../app/activate-shooter.php"; break; } case 'payment': { include "../app/activate-shooter.php"; break; } case 'add-shooter': { include "../app/add-shooter.php"; $template = "add-shooter.tpl"; break; } case 'edit-shooter': { include "../app/edit-shooter.php"; $template = "edit-shooter.tpl"; break; } case 'select-csv': { include "../app/select-csv.php"; $template = "select-csv.tpl"; break; } case 'csv': { include "../app/csv.php"; break; } case 'import-csv': { $template = 'import-csv.tpl'; if(isset($_GET['type'])) include "../app/import-shooters.php"; break; } default: { include "../app/index.php"; $template = "index.tpl"; break; } } $smarty->assign('queries', dibi::$numOfQueries); $smarty->assign("queryTime", dibi::$totalTime); if(trim($template)) $smarty->display($template); //$ret = ob_get_clean(); //header("X-Original-Content-Lenght: " . strlen($ret)); //// Gzip/Deflate/Bzip2 compression //if(stristr($_SERVER["HTTP_ACCEPT_ENCODING"], "bzip2")) //{ // $ret = bzcompress($ret, 9); // header("Content-Encoding: bzip2"); //} //elseif(stristr($_SERVER["HTTP_ACCEPT_ENCODING"], "gzip")) //{ // $ret = gzencode($ret, 9); // header("Content-Encoding: gzip"); //} //elseif (stristr($_SERVER["HTTP_ACCEPT_ENCODING"], "deflate")) //{ // $ret = gzdeflate($ret, 9); // header("Content-Encoding: deflate"); //} // //header("Content-length: " . strlen($ret)); //echo $ret;