调用某个栏目最新内容的方法
  • 2021-01-28
  • 作者:admin
  • 浏览量:504
  • 所属分类:KUICMS
  • 不包含子栏目内容的方法:

    1{kuicms:rs top="10" table="kui_content" where="islock=1 and classid=栏目ID" order="ontop desc,ordnum desc,id desc"}

    2{rs:eof}暂无资料{/rs:eof}

    3<a href="{$rs[link]}" title="{$rs[title]}">{cutstr($rs[title],80,1)}</a>

    4{/kuicms:rs}


    包含子栏目内容的方法:

    1{php $sonid=get_sonid_all(栏目ID)}

    2{sdcms:rs top="10" table="sd_content" where="islock=1 and classid in($sonid)" order="ontop desc,ordnum desc,id desc"}

    3{rs:eof}暂无资料{/rs:eof}

    4<a href="{$rs[link]}" title="{$rs[title]}">{cutstr($rs[title],80,1)}</a>

    5{/sdcms:rs}

    说明:先定义$sonid变量获取栏目的所有子栏目集合,然后在where参数中直接调用$sonid即可


    调用内容所属栏目的方法(带超链接)

    1<a href="{cateurl($rs[classid])}">{get_catename($rs[classid])}</a>


    您当前浏览的内容:《调用某个栏目最新内容的方法》由魁网科技(重庆)有限公司旗下微信小程序开发平台《云客盒子旗下》整理发布,内容题材来源于网络如有侵权请联系:qicaihd@qq.com 删除!
    如需转载请注明:https://www.kui.net/news/2488.html
    以上信息是否解决您的问题?

    没找到想要的答案?

    联系我们获得更多信息,请描述一下您遇到的问题。

    现在就与专业咨询顾问沟通!
    img
    客服热线 4000-023-991
    img 信息保护中请放心填写
    # 微信咨询:
    #1 售前咨询
    售前咨询
    #2 售后服务
    售后服务
    嘿,我来帮您!