PHP Classes

File: upload/themes/bb_simple/model/Threads.php

Recommend this page to a friend!
  Classes of James Brows   PHP Bulletin Board   upload/themes/bb_simple/model/Threads.php   Download  
File: upload/themes/bb_simple/model/Threads.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: PHP Bulletin Board
Manage and post messages in multi-user forums
Author: By
Last change:
Date: 2 years ago
Size: 1,126 bytes
 

Contents

Class file image Download
<?php

function user_ranks_render($user_id)
{
   
$rankData=BB_UserRanks::load_by_userid($user_id);

   
$total=count($rankData);

   
$li='';
    for (
$i=0; $i < $total; $i++) {

        if(
$rankData[$i]['image']!=null && strlen($rankData[$i]['image']) > 5)
        {
           
$li.='<div style="width:100%;"><img src="'.SITE_URL.$rankData[$i]['image'].'" style="width:100%;" /></div>';
        }
        else
        {
           
$li.='<span class="card-title block " style="background-color:'.$rankData[$i]['bg_color_c'].'">'.$rankData[$i]['title'].'</span>';
        }
       
    }

    return
$li;
}


function
bb_gen_breadcum_forum_data($forum_id,$listCategories=array())
{
    if(!isset(
Configs::$_['forum_breadcum_data']))
    {
       
Configs::$_['forum_breadcum_data']=[];
    }

   
$total=count($listCategories);

    for (
$i=0; $i < $total; $i++) {
        if(
$forum_id==$listCategories[$i]['forum_id'])
        {
           
array_push(Configs::$_['forum_breadcum_data'],$listCategories[$i]);

           
bb_gen_breadcum_forum_data($listCategories[$i]['parent_id'],$listCategories);
        }
    }
}