设为首页 加入收藏

TOP

Dedecms联动类型两级变一级的办法
2011-08-21 04:32:51 来源: 作者: 【 】 浏览:587次 评论:0

Dedecms联动类型两级变一级的办法,这个相信大家都很需要吧,现在就来说一下如何修改文件,找到infolink.lib.php

以下代码都注掉
/*
$sontype = ( ($househx % 500 != 0) ? $househx : 0 );
$toptype = ( ($househx % 500 == 0) ? $househx : ( $househx-($membertype%500) ) );
$fields['househx'] = "<a href='{$baseurl}plus/list.php?channelid={$channelid}&tid={$typeid}&househx={$toptype}&nativeplace={$nativeplace}'><b>{$em_househxs[$toptype]}</b></a> ";

下级显示不显示
foreach($em_househxs as $eid=>$em)
{
if($eid < $toptype+1 || $eid > $toptype+499) continue;
if($eid == $househx) {
$fields['househx'] .= " <b>{$em}</b>";
}
else {
$fields['househx'] .= " <a href='{$baseurl}plus/list.php?channelid={$channelid}&tid={$typeid}&househx={$eid}&nativeplace={$nativeplace}'>{$em}</a>";
}
}
*/

换成

foreach($em_househxs as $eid=>$em)
{
if($eid % 500 != 0) continue;
if(isset($_GET['househx']))
{
$navclass=$_GET['househx'];
if ($navclass==$eid)
{
$navclass=' style=color:#ff0000';
}
$fields['househx'] .= " <a href='{$baseurl}plus/list.php?channelid={$channelid}&tid={$typeid}&househx={$eid}&nativeplace={$nativeplace}'".$navclass.">{$em}</a>";
}
} liehuo.烈火.net学院

您看到此篇文章时的感受是:
Tags: 责任编辑:administrator
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到QQ空间
分享到: 
上一篇Dedecms列表页读取内容页图片的实.. 下一篇phpcms黄页common.inc.php on lin..

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容:

相关栏目

最新文章

图片主题

热门文章

推荐文章

相关文章

广告位