mv 具体不是很清楚
源代码在线查看: list.php
require("global.php");
@include("php168/guide_fid.php");
if(!$fid&&$webdb[Mv_NewsMakeHtml]==2)
{
//伪静态处理
Explain_HtmlUrl();
}
if(!$fid)
{
showerr("FID不存在");
}
$GuideFid[$fid]=str_replace("'$webdb[www_url]'","'$Mdomain'",$GuideFid[$fid]);
$fidDB=$db->get_one("SELECT * FROM {$pre}mv_sort WHERE fid='$fid'");
$fidDB[config]=unserialize($fidDB[config]);
//SEO
$titleDB[title] = filtrate("$fidDB[name] - $webdb[Mv_webname] - $titleDB[title]");
$titleDB[keywords] = $titleDB[description] = filtrate("$webdb[Mv_webname] - $webdb[Mv_metakeywords] - $titleDB[title] - $titleDB[keywords]");
//栏目风格
$fidDB[style] && $STYLE=$fidDB[style];
//列表页多少个视频
$Lrows=$fidDB[maxperpage]?$fidDB[maxperpage]:15;
//分类设置了显示子栏目中的几个.就为最高优先级
if($fidDB[config][sonTitleRow]>0){
$moresortROWS=$fidDB[config][sonTitleRow];
}
if($fidDB[config][sonTitleLeng]>0){
$moresortLeng=$fidDB[config][sonTitleLeng];
}
if($fidDB[type])
{
$listdb_moresort=ListMoreSort($moresortROWS>0?$moresortROWS:5,$moresortLeng>0?$moresortLeng:40);
$chdb[main_tpl]=getTpl("bigsort",$FidTpl['list']);
}
else
{
$listdb=ListThisSort($Lrows,$leng=50);
$showpage=getpage("{$pre}mv_video","WHERE fid=$fid","list.php?fid=$fid",$Lrows);
$chdb[main_tpl]=getTpl("sort",$FidTpl['list']);
}
/**
*标签
**/
$ch_fid = intval($fidDB[config][label_list]); //是否定义了栏目专用标签
$ch_pagetype = 2; //2,为list页,3,为bencandy页
$ch_module = $webdb[module_id]?$webdb[module_id]:3; //文章模块,默认为0
$ch = 0; //不属于任何专题
@include(PHP168_PATH."inc/label_module.php");
require("head.php");
if($fidDB[type]==1){
require(getTpl("bigsort"));
}else{
require(getTpl("sort"));
}
require("foot.php");
//伪静态处理
if($webdb[Mv_NewsMakeHtml]==2){
$content=ob_get_contents();
ob_end_clean();
$content=fake_html($content);
echo "$content";
}
function ListThisSort($rows,$leng){
global $page,$fid;
if($page $page=1;
}
$min=($page-1)*$rows;
$SQL="WHERE fid=$fid AND yz=1 ORDER BY list DESC LIMIT $min,$rows";
$which='*';
$listdb=list_content($SQL,$which,$leng);
return $listdb;
}
function ListMoreSort($rows,$leng){
global $db,$pre,$fid;
$query=$db->query("SELECT * FROM {$pre}mv_sort WHERE fup=$fid AND forbidshow=0 ORDER BY list DESC");
while($rs=$db->fetch_array($query)){
$SQL="WHERE fid=$rs[fid] AND yz=1 ORDER BY id DESC LIMIT $rows";
$which='*';
$rs[article]=list_content($SQL,$which,$leng);
//如果本栏目不能获取到内容,将获取其所有子栏目的内容
if(!$rs[article])
{
$array_fid=Get_SonFid("{$pre}mv_sort",$rs[fid]);
if($array_fid)
{
$SQL="WHERE fid IN (".implode(',',$array_fid).") AND yz=1 ORDER BY id DESC LIMIT $rows";
$rs[article]=list_content($SQL,$which,$leng);
}
}
$rs[logo] && $rs[logo]=tempdir($rs[logo]);
$listdb[]=$rs;
}
return $listdb;
}
?>