Home  >  Article  >  php教程  >  ThinkPHP调用织梦dedecms文章代码

ThinkPHP调用织梦dedecms文章代码

WBOY
WBOYOriginal
2016-06-07 11:40:231541browse

ThinkPHP调用织梦dedecms文章代码
php代码$PS=M("Archives","表前缀","mysql://用户名:密码@localhost:3306/表名");<br>         $where['typeid']=8;//取栏目id=8的数据 <br>         $NewPS=$PS->where($where)->order('pubdate desc')->limit(8)->select();<br>         $this->assign("NewPS",$NewPS);模板代码//说明 链接写绝对的,日期直接调用,最后是文章id号,就完事了,必须调用指定的栏目,必须是二级,顶级下包含了下级是不行的,因为你生成的二级目录名字不一样,调用全站只能全站文章用动态,否则只能单个栏目调用<br>     <volist><br>                 <li> <a>{:msubstr($vo['title'],0,18)}...</a><br>                 <font>{$vo.pubdate|date='m-d',###}</font><br>                 </li> <br>                 </volist>效果图下
ThinkPHP调用织梦dedecms文章代码
地址: http://www.qq839.com/ 首页PS大学板块
更多交流+Q839024615

AD:真正免费,域名+虚机+企业邮箱=0元

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn