商品对比

我的购物车

您好, 欢迎来到   Conmeng商城 [ 登录 ]  [ 注册 ]     [ 中国 ]   [ 切换语言 ]

扫描二维码

下载手机客户端
我的商城

最近浏览的商品

全部浏览历史
购物车结算

最新加入的商品

首页> 新闻资讯

最新新闻

假如让动漫人物去参加鱿鱼游戏,那么这个游戏会变成什么样

2018-02-10 12:54:59

 public function _category($catid)
{

$catid = str_replace("category_","",$catid);
$catid=(int) $catid;

$search='';
if(!empty($catid)){
$sortpath=$this->db->fetch_one("select sort_path from ".WEBMENG_CONMENG."category_record where cat_id='".$catid."'  ");
$search.=" and catid in(select cat_id from ".WEBMENG_CONMENG."category_record where sort_path like '".$sortpath."%') ";
}

$sql = "select *,thumb as img,inputtime as addtime from ".WEBMENG_CONMENG."record where catid='".$catid."' order by inputtime desc ";


$all_record = page_for_db_extend($sql);  //查询带分页的
$data = array(
'info_reslut' => $all_record['data'],
'showpage'    => $all_record['page'],
'category'   => $this->_category_record()
);

$settings = array();
$sets = $this->db->fetch("select * from ".WEBMENG_CONMENG."settings  ");
if(!empty($sets)){
foreach ($sets as $v) {
$webmeng[$v['variable']] = $v;
}
}
$data['webmeng'] = $webmeng;    /*获取内页调用系统信息如LOGO 网站名称*/




$this->display('record/category.html',$data);
}



public function _category_record()
{




$record_list  = $this->db->fetch("select cat_name as sortname,cat_id as id,parent_id from ".WEBMENG_CONMENG."category_record  ");
$category = array();
$parent = array();
if(!empty($record_list)){
foreach ($record_list as  $v) {
if($v['parent_id']==0){
$category[] = $v;
}
$parent[$v['parent_id']][]=$v;
}
foreach ($category as $k => $v) {
$category[$k]['child'] = isset($parent[$v['id']])?$parent[$v['id']]:array();
if(!empty($category[$k]['child'])){
foreach ($category[$k]['child'] as $key => $value) {
$category[$k]['child'][$key]['child'] = isset($parent[$value['id']])?$parent[$value['id']]:array();
}
}
}
}
return $category;
}

请填写您的客服代码
如果您没有统计代码,推荐使用搜寻分析工具!