織夢如何在列表語句中做if判斷

2020-12-09



1 {dede:list pagesize='4'
2                                     [field:array  runphp='yes'
3                                     if(@me['zhiweishuxing']=='熱招職位'
4                                     
5     @me = (strlen(@me['title'])>20) ? ('<li><a href='.@me['arcurl'].'>'.cn_substr(@me['title'],30).'...'.'</a></li>') :('<li><a href='.@me['arcurl'].'>'.@me['title'].'</a></li>');                                  
6                                             
7                                         }        
8                                      [/field:array]          
9
0
凯时平台