本文整理汇总了PHP中category::get_categories方法的典型用法代码示例。如果您正苦于以下问题:PHP category::get_categories方法的具体用法?PHP category::get_categories怎么用?PHP category::get_categories使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类category
的用法示例。
在下文中一共展示了category::get_categories方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _
case "manage_waitinglist":
$smarty_q->assign("h1", "");
$smarty_q->assign("fake_h1", _("Quotation waitinglist"));
$smarty_q->assign ("quotes", quote::get_from_waitinglist());
arr(quote::get_from_waitinglist());
break;
// A temporary solution to activate quotations
case "manage_not_active_quotations":
acl();
if (isset($_POST["manage_not_active_quotations"]))
{
quote::set_random_quote($_POST);
}
$smarty_q->assign("h1", "");
$smarty_q->assign("fake_h1", _("Activate random quote"));
$smarty_q->assign("categories", category::get_categories());
$smarty_q->assign("manage_not_active_quotations", true);
$quotes_temp = quote::get_random_quote();
//arr($quotes_temp);
$smarty_q->assign("id", $quotes_temp[0]["id"]);
$smarty_q->assign("q_id", $quotes_temp[0]["q_id"]);
$smarty_q->assign("quote", $quotes_temp[0]["quote"]);
$smarty_q->assign("tag", $quotes_temp[0]["tag"]);
$smarty_q->assign("author_id", $quotes_temp[0]["author_id"]);
$smarty_q->assign("author_name", $quotes_temp[0]["author_name"]);
$smarty_q->assign("category_id", $quotes_temp[0]["category_id"]);
$smarty_q->assign("author_born_death", $quotes_temp[0]["author_born_death"]);
$smarty_q->assign("source_title_original", $quotes_temp[0]["source_title_original"]);
$smarty_q->assign("author_firstname_et", $quotes_temp[0]["author_firstname_et"]);
$smarty_q->assign("author_firstname_en", $quotes_temp[0]["author_firstname_en"]);
$smarty_q->assign("author_firstname_de", $quotes_temp[0]["author_firstname_de"]);
示例2: _
//$smarty_q->assign ("for_nerds", _("For nerds :)"));
$context["for_nerds"] = _("For nerds :)");
//$smarty_q->assign ("lang", substr($config_q["locale"], 0, 2));
$context["lang"] = substr($config_q["locale"], 0, 2);
//$smarty_q->assign ("rpx_language_preference", $config_q["rpx"]["language_preference"]);
//$smarty_q->assign ("quotes2", _("quotes"));
//$smarty_q->assign ("authors2", _("authors"));
//$smarty_q->assign ("sources2", _("sources"));
//$smarty_q->assign ("tags2", _("tags"));
//$smarty_q->assign ("about_quotebook", _("About QuoteBook24.com "));
//$smarty_q->assign ("section", $section);
$context["section"] = $section;
if ($user->data["user_id"]==2)
{
$context["admin"] = true;
$context["categories"] = $category->get_categories();
}
$context["username"] = $user->data["username"];
$context["username_clean"] = $user->data["username_clean"];
$context["user_id"] = $user->data["user_id"];
//$smarty_q->assign ("user_type", $user->data["user_type"]);
//$smarty_q->assign ("group_id", $user->data["group_id"]);
//$smarty_q->assign ("robots_index", false);
//$smarty_q->assign ("keywords", _("quotes, quotations, world"));
//$smarty_q->assign ("author_index", author::get_author_index());
$context["author_index"] = author::get_author_index();
//$smarty_q->author_index ("tag_index", tag::get_tag_index());
$context["tag_index"] = tag::get_tag_index();
//$smarty_q->assign ("category_index", category::get_categories());
//$smarty_q->assign ("a_path", $a_path);