Home >Backend Development >PHP Tutorial >php 如何循环从第4条记录以后的LI class="selc"

php 如何循环从第4条记录以后的LI class="selc"

WBOY
WBOYOriginal
2016-06-20 12:29:16778browse

如题,现在这样写只能第2条li =selc
{php $j=1;}
 {loop $data $r}
 

  • {str_cut($r['catname'],12,'')}

  •  {$j++}
     {/loop} 


    回复讨论(解决方案)

     

  • =4} class="selc"{/if} href="{str_replace('http://www.','http://m.',$r[url])}">{str_cut($r['catname'],12,'')}
  • 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