phpcms v9列表页如何调用子栏目如首页>产品中心>产品类型a

问题:

phpcms v9列表页如何调用子栏目如:首页>产品中心>产品类型a>产品类型a11

在列表页产品类型a中,包括产品类型a1、产品类型a2、产品类型a3

如何在列表页的category调用出来

产品类型a1、产品类型a2、产品类型a3 三种类型!

回答: 



{pc:content action="category" catid="$catid" num="99" order="listorder ASC"}
{loop $data $cat}
{pc:content action="lists" catid="$cat['catid']" order="id DESC" num="6" return="subcate"}
{if $subcate}
<h2><a href="{$cat['url']}">{$cat['catname']}</a></h2>
<ul class="news_list">
{loop $subcate $r}
<li><span>{date('Y/m/d H:i',$r['inputtime'])}</span><a{if $n==1} class="b"{/if} href="{$r['url']}">{$r['title']}</a></li>
{/loop}
</ul>
{/if}
{/pc}
{/loop}
{/pc}

或者 


{pc:get sql="select * from phpcms_category where catid in(你的子栏目ID)" return="data"}
{loop $data $r}
<a href="{$r['url']}">{$r['catname']}</a>
{/loop}
{/pc}

如果你的子栏目ID是8,9,10的话,条件哪里就写成in(8,10)

相关文章

本教程操作系统:Windows10系统、phpcms 9版本、Dell G3电脑...
PHPcms访问特点:单一入口模式。无论访问任何一个模块或者功...
例如:{pc:contentaction="position"posid="...
首先,上图之中的红色框框是没有的,我们想要给他加上,当然...
头部<metaname="keywords"content="{$SEO...
做网站时用的到的简单的栏目导航()phpcms多个栏目catidin(9,...