shuipFCMS二次开发记录一
来源:互联网 发布:免费cd刻录软件 编辑:程序博客网 时间:2024/04/30 11:27
首先,随便在后台管理栏目,找到设计欣赏,选择更改标题 还有 绑定域名,然后在“模板设置”处查看引用的“栏目首页模板”是category_heng.php.
然后通过以下三点更改,即可取出只有第三方连接的导航栏目
1.contengTagLib.class.php页面
public function category1($data) {
//缓存时间
$cache = (int) $data['cache'];
$cacheID = to_guid_string($data);
if ($cache && $array = S($cacheID)) {
return $array;
}
$data['catid'] = intval($data['catid']);
$where = $array = array();
//设置SQL where 部分
if (isset($data['where']) && $data['where']) {
$where['_string'] = $data['where'];
}
$db = M("Category");
$num = (int) $data['num'];
if (isset($data['catid'])) {
$where['ismenu'] = array("EQ", 1);
$where['parentid'] = array("EQ", $data['catid']);
$where['url'] = array("like", "http://%");//like http://,这样就获取到不是外站的第三方连接
}
//如果条件不为空,进行查库
if (!empty($where)) {
if ($num) {
$categorys = $db->where($where)->limit($num)->order($data['order'])->select();
} else {
$categorys = $db->where($where)->order($data['order'])->select();
}
}
//结果进行缓存
if ($cache) {
S($cacheID, $categorys, $cache);
}
return $categorys;
}
2.<template file="Contents/header1.php"/>
3.<content action="category1" catid="0" order="listorder ASC" >
- shuipFCMS二次开发记录一
- shuipfcms二次开发之图片上传
- shuipFCMS的开发记录
- openstack学习记录(一) horizon二次开发部署(juno)
- uchome二次开发记录
- 微米系统二次开发记录
- 泛微二次开发记录
- shuipFCMS后台去版权
- shuipFCMS收集2
- ecshop二次开发bug(一)
- EcShop二次开发学习方法<一>
- PHPCMS二次开发笔记一
- MasterCAM二次开发(一)
- Cad二次开发(一)
- Catia CAA二次开发系列一
- Nutch二次开发总结(一)
- Nutch二次开发总结(一)
- ECSHOP后台二次开发教程(一)
- UML基础:类图
- Linux 如何安装tar.gz文件
- 融合敏捷与规范:打造高效项目团队
- 二分查找法实现
- linux awk命令详解
- shuipFCMS二次开发记录一
- 进程的概念和特征
- Android 最火的快速开发框架XUtils
- [leetcode] Path Sum II
- hadoop进阶视频
- POJ1062昂贵的聘礼
- 2-2. 然后是几点(15)
- HTML实体字符
- php简介的发送邮件