您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

一段代码求解

2025/7/7 2:37:06发布34次查看
' selected');
$auclist=c::t('auction_inauctions')->fetch_all_by_sql('status=1 and uid='.$_g['uid'].' and ovtime>'.strtotime(date(y-m-d h:i:s)),'order by inputtime desc',$start,$perpage);
$count=c::t('auction_inauctions')->fetch_all_by_sql('status=1 and uid='.$_g['uid'].' and ovtime $multipage = multi($count, $perpage, $page, $mpurl);
include template('home/auction_inauctions');
?>
请高手讲解下以上代码,能逐行讲解最好了,谢谢!
回复讨论(解决方案) 显示某一页的数据
每页30行,从数据库取得数据然后用一个template显示
' selected');$auclist=c::t('auction_inauctions')->fetch_all_by_sql('status=1 and uid='.$_g['uid'].' and ovtime>'.strtotime(date(y-m-d h:i:s)),'order by inputtime desc',$start,$perpage);//c是discuz数据库操作的静态类,t方法指定操作的表 fetch_all_by_sql加查询条件得到结果集$count=c::t('auction_inauctions')->fetch_all_by_sql('status=1 and uid='.$_g['uid'].' and ovtime
' selected');  
$auclist=c::t('auction_inauctions')->fetch_all_by_sql('status=1 and uid='.$_g['uid'].' and ovtime>'.strtotime(date(y-m-d h:i:s)),'order by inputtime desc',$start,$perpage); //查询出来数据放在$auclist里边;
$count=c::t('auction_inauctions')->fetch_all_by_sql('status=1 and uid='.$_g['uid'].' and ovtime $multipage = multi($count, $perpage, $page, $mpurl); //多页? multi这玩意是个函数吧
include template('home/auction_inauctions'); //显示页面么;
?>
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product