本文整理汇总了PHP中bbp_forum_class函数的典型用法代码示例。如果您正苦于以下问题:PHP bbp_forum_class函数的具体用法?PHP bbp_forum_class怎么用?PHP bbp_forum_class使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了bbp_forum_class函数的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: bbp_forum_id
<?php
/**
* Forums Loop - Single Forum
*
* @package bbPress
* @subpackage Theme
*/
?>
<ul id="bbp-forum-<?php
bbp_forum_id();
?>
" <?php
bbp_forum_class();
?>
>
<li class="bbp-forum-info">
<?php
do_action('bbp_theme_before_forum_title');
?>
<a class="bbp-forum-title" href="<?php
bbp_forum_permalink();
?>
"><?php
bbp_forum_title();
?>
</a>
示例2: ipt_kb_bbp_list_subforums
/**
* List subforums or forums
*
* Must be called within a loop or be assigned an forum id
*
* @param mixed $args The function supports these args:
* - forum_id: Forum id. Defaults to ''
* @uses bbp_forum_get_subforums() To check if the forum has subforums or not
* @uses bbp_get_forum_permalink() To get forum permalink
* @uses bbp_get_forum_title() To get forum title
* @uses bbp_is_forum_category() To check if a forum is a category
* @uses bbp_get_forum_topic_count() To get forum topic count
* @uses bbp_get_forum_reply_count() To get forum reply count
* @return void
*/
function ipt_kb_bbp_list_subforums($args = array())
{
$r = bbp_parse_args($args, array('forum_id' => ''), 'ipt_kb_list_forums');
$sub_forums = bbp_forum_get_subforums($r['forum_id']);
if (!empty($sub_forums)) {
foreach ($sub_forums as $sub_forum) {
?>
<li class="<?php
if (bbp_is_forum_category($sub_forum->ID)) {
echo 'bbp-forum-is-category';
}
?>
list-group-item bbp-body ipt_kb_subforum_list">
<?php
do_action('bbp_theme_before_forum_sub_forums');
?>
<ul id="bbp-forum-<?php
bbp_forum_id($sub_forum->ID);
?>
" <?php
bbp_forum_class($sub_forum->ID);
?>
>
<li class="bbp-forum-info">
<span class="pull-left ipt_kb_bbpress_subforum_icon ipt_kb_bbpress_forum_icon">
<?php
if (bbp_is_forum_category($sub_forum->ID)) {
?>
<span class="glyphicon ipt-icomoon-folder-open"></span>
<?php
} else {
?>
<span class="glyphicon ipt-icomoon-file4"></span>
<?php
}
?>
</span>
<?php
ipt_kb_bbp_forum_title_in_list($sub_forum->ID);
?>
<?php
ipt_kb_bbp_forum_description_in_list($sub_forum->ID);
?>
<?php
bbp_forum_row_actions();
?>
</li>
<li class="bbp-forum-topic-count">
<?php
bbp_forum_topic_count($sub_forum->ID);
?>
</li>
<li class="bbp-forum-reply-count">
<?php
bbp_show_lead_topic() ? bbp_forum_reply_count($sub_forum->ID) : bbp_forum_post_count($sub_forum->ID);
?>
</li>
<li class="bbp-forum-freshness">
<?php
ipt_kb_bbp_forum_freshness_in_list($sub_forum->ID);
?>
</li>
</ul>
<?php
do_action('bbp_theme_after_forum_sub_forums');
?>
<div class="clearfix"></div>
</li>
<?php
}
}
}
示例3: get_post_meta
/**
* Forums Loop - Single Forum
*
* @package bbPress
* @subpackage Theme
*/
global $helper;
$image = get_post_meta(bbp_get_forum_id(), 'image', true);
$depth = count(get_post_ancestors(bbp_get_forum_id()));
?>
<ul id="bbp-forum-<?php
bbp_forum_id();
?>
" <?php
bbp_forum_class(bbp_get_forum_id(), array('clearfix'));
?>
>
<li class="bbp-forum-info">
<div class="title-bar">
<?php
do_action('bbp_theme_before_forum_title');
?>
<h4><a class="bbp-forum-title" href="<?php
bbp_forum_permalink();
?>
"><?php
bbp_forum_title();
示例4: bbp_forum_id
<?php
/**
* Forums Loop - Single Forum
*
* @package bbPress
* @subpackage Theme
*/
?>
<ul id="bbp-forum-<?php
bbp_forum_id();
?>
" <?php
bbp_forum_class(bbp_get_forum_id(), array('row'));
?>
>
<div class="sub-divider">
<li class="bbp-forum-info col-lg-8">
<?php
do_action('bbp_theme_before_forum_title');
?>
<a class="bbp-forum-title" href="<?php
bbp_forum_permalink();
?>
" title="<?php
bbp_forum_title();
示例5: bbp_forum_id
<?php
$nice_ul_class = '';
?>
<?php
if (!is_single() && get_the_content() == '') {
$nice_ul_class = 'no-content';
}
?>
<ul id="bbp-forum-<?php
bbp_forum_id();
?>
" <?php
bbp_forum_class(bbp_get_forum_id(), array($nice_ul_class));
?>
>
<li class="bbp-forum-info clearfix">
<?php
if (!is_single()) {
?>
<div class="bbp-forum-header">
<?php
do_action('bbp_theme_before_forum_title');
?>
<h3><a class="bbp-forum-title" href="<?php
示例6: bbp_forum_id
<?php
/**
* Forums Loop - Single Forum
*
* @package bbPress
* @subpackage Theme
*/
?>
<ul id="bbp-forum-<?php
bbp_forum_id();
?>
" <?php
bbp_forum_class(null, 'single-forum');
?>
>
<li class="bbp-forum-info">
<?php
if (bbp_is_user_home() && bbp_is_subscriptions()) {
?>
<span class="bbp-row-actions">
<?php
do_action('bbp_theme_before_forum_subscription_action');
?>
<?php