本文整理匯總了PHP中URLBuilder::getPage方法的典型用法代碼示例。如果您正苦於以下問題:PHP URLBuilder::getPage方法的具體用法?PHP URLBuilder::getPage怎麽用?PHP URLBuilder::getPage使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類URLBuilder
的用法示例。
在下文中一共展示了URLBuilder::getPage方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: DisplayTime
require_once __DIR__ . "/classes/display/urlbuilder.php";
require_once __DIR__ . "/classes/backend.php";
//"Config"
require_once __DIR__ . "/config/settings.php";
include_once __DIR__ . "/config/information.php";
//instances of the classes
$displayTime = new DisplayTime();
$displayTime->setUnsafeStartDate(isset($_GET['year']) ? $_GET['year'] : null, isset($_GET['month']) ? $_GET['month'] : null);
$displayTime->setUnsafeEndDate(isset($_GET['year']) ? $_GET['year'] : null, isset($_GET['month']) ? $_GET['month'] : null);
$urlBuilder = new URLBuilder(isset($_GET['show']) ? $_GET['show'] : null, $lang->getLanguage());
$backend = new Backend();
if (isset($_GET['length'])) {
$backend->setUnsafeListLength($_GET['length']);
}
//set Page title
switch ($urlBuilder->getPage()) {
case "about":
$fstat_title = FLANG_H_ABOUT_FSTAT;
break;
case "last":
$fstat_title = FLANG_H_LAST . " " . $backend->getListLength() . " " . FLANG_VISITOR_L;
break;
case "lastbots":
$fstat_title = FLANG_H_LAST . " " . $backend->getListLength() . " " . FLANG_BOT_L;
break;
case "overview":
default:
$fstat_title = FLANG_H_STATFOR . " " . $lang->monthnames[$displayTime->getStartMonth() - 1] . " " . $displayTime->getStartYear();
break;
}
?>