【发布时间】:2019-11-16 19:32:39
【问题描述】:
我试图在 ModX 的 if 语句中输出一个模板变量,但它没有输出。
我有多个带有文章链接的页面,关键是只在第一页上输出模板变量内容,而不是在其他页面上。
// This gives no output:
[[!#get.page:is=`1`:or:is=``:then=`[[*content]]`:else=``]
// This outputs "yes" on the first page and "no" on others:
[[!#get.page:is=`1`:or:is=``:then=`yes`:else=`no`]]
我什至试过这个,但它仍然没有给出任何输出。我想问题不在于输出修饰符:
[[!#get.page:is=`1`:or:is=``:then=`[[*content]]`:else=`[[*content]]`]
我正在使用 ModX Revo 2.7.0
任何帮助表示赞赏,在此先感谢!
【问题讨论】:
标签: modx modx-revolution