muban大师 发表于 2018-8-15 08:18:03

织梦判断某字段为空就显示自定义的内容

有时候织梦自定义字段,如果没有值的时候要显示指定的默认内容,该如何操作
       
        {dede:field name='jiage' runphp='yes'}
       
             if(@me=='')
       
          { @me = '' ;}
       
                else
       
                { @me = ""; }
       
       {/dede:field}
       
        jiage是自定义字段
页: [1]
查看完整版本: 织梦判断某字段为空就显示自定义的内容