本文整理匯總了PHP中categories::generateList方法的典型用法代碼示例。如果您正苦於以下問題:PHP categories::generateList方法的具體用法?PHP categories::generateList怎麽用?PHP categories::generateList使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類categories
的用法示例。
在下文中一共展示了categories::generateList方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: abr
abr('paging', paging('/' . $languageURL . 'categories/' . $categoryID . '/?p=', '&sort_by=' . $_GET['sort_by'] . '&order=' . $_GET['order'], PAGE, $limit, $itemsClass->foundRows));
#加載類別
require_once ROOT_PATH . '/apps/categories/models/categories.class.php';
$categoriesClass = new categories();
$categories = $categoriesClass->getAll();
abr('categories', $categories);
#麵包屑
if (isset($categoryID) && is_numeric($categoryID)) {
#設置元信息
if ($category['meta_title'] != '') {
$smarty->assign('title', $category['meta_title']);
} else {
$smarty->assign('title', $category['name']);
}
if ($category['meta_keywords'] != '') {
$smarty->assign('meta_keywords', $category['meta_keywords']);
}
if ($category['meta_description'] != '') {
$smarty->assign('meta_description', $category['meta_description']);
}
abr('breadcrumb', '<a href="/' . $languageURL . '" title="">' . $langArray['home'] . '</a> \\ <a href="/' . $languageURL . 'categories/" title="">' . $langArray['categories'] . '</a> \\ <a href="/' . $languageURL . 'categories/' . $category['id'] . '" title="">' . $category['name'] . '</a>');
} else {
abr('breadcrumb', '<a href="/' . $languageURL . '" title="">' . $langArray['home'] . '</a> \\ <a href="/' . $languageURL . 'categories/" title="">' . $langArray['categories'] . '</a> \\ <a href="/' . $languageURL . 'categories/all" title="">' . $langArray['all_files'] . '</a>');
}
} else {
$allCategories = $categoriesClass->getAllWithChilds(0, " `visible` = 'true' ");
$categoriesList = $categoriesClass->generateList($allCategories);
abr('categoriesList', $categoriesList);
#麵包屑
abr('breadcrumb', '<a href="/' . $languageURL . '" title="">' . $langArray['home'] . '</a> \\ <a href="/' . $languageURL . 'categories/" title="">' . $langArray['categories'] . '</a>');
}