帝国CMS灵动标签调用指定某个时间段的信息(日期时间归档)多种写法

主要是对这篇文章的补充https://www.moyublog.com/notes/317.html

1、某天发布的文章
[e:loop={‘news’,10,18,0,’newstime>=’.to_time(‘2010-11-11 00:00:01′).’ and newstime<=’.to_time(‘2010-11-11 23:59:59’).”}]
” target=”_blank”>

[/e:loop]

或 (to_time 换成  to_date)

[e:loop={‘news’,10,18,0,’newstime>=’.to_date(‘2016-07-31 00:00:01′).’ and newstime<=’.to_date(‘2016-08-31 23:59:59’).”}]
” target=”_blank”>

[/e:loop]

2、某一段时间发布的文章
[e:loop={‘news’,10,18,0,’newstime>=’.to_time(‘2016-07-31 00:00:01′).’ and newstime<=’.to_time(‘2016-08-31 23:59:59’).”}]
” target=”_blank”>

[/e:loop]

  • ” target=”_blank”>

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注