當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Region::get_tree方法代碼示例

本文整理匯總了PHP中Region::get_tree方法的典型用法代碼示例。如果您正苦於以下問題:PHP Region::get_tree方法的具體用法?PHP Region::get_tree怎麽用?PHP Region::get_tree使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Region的用法示例。


在下文中一共展示了Region::get_tree方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: db

include "{$docroot}/db-category.php";
include "{$docroot}/db-expiry.php";
include "{$docroot}/db-static-content.php";
include "{$docroot}/db-user.php";
include "{$docroot}/db-user-banned.php";
include "{$docroot}/db-response.php";
include "{$docroot}/db-ad-review.php";
include "{$docroot}/db-favourite.php";
include "{$docroot}/db-user-review.php";
include "{$docroot}/db-report.php";
$db = new db();
if (!$db->connect()) {
    exit(mysql_error());
}
$categories = Category::get_tree();
$regions = Region::get_tree();
$statics = StaticContent::get_all(array(), 'id>6');
//counters
$today = date("Y-m-d", time());
$ct_fresh = Ad::count(array('active' => 1), "lastmodified>='{$today}'");
$ct_all = Ad::count(array('active' => 1));
$ct_expirys = Ad::count(array('active' => 1, "DATEDIFF(expiry,'{$today}')" => 0));
//menu and breadcumb
$menu = User::get_menu();
$current_script_name = basename($_SERVER['SCRIPT_NAME']);
if (strpos($current_script_name, '-') > 0) {
    $current_page = explode('-', $current_script_name, 2);
    if (isset($current_page[2])) {
        $current_page[1] .= '-' . $current_page[2];
    }
    //php 5.3.5 bug?? workaround
開發者ID:noverkill,項目名稱:classified-ads-script,代碼行數:31,代碼來源:common.php


注:本文中的Region::get_tree方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。