帝国CMS调用某一栏目,指定时间内的所有信息

帝国CMS,万能标签或者灵动标签,调用某一栏目,指定时间内的所有信息。
例如调用2020年的所有信息,SQL语句如下:

select * from [!db.pre!]ecms_news where newstime>=UNIX_TIMESTAMP('2020-01-01 00:00:01') and newstime<=UNIX_TIMESTAMP('2020-12-31 23:59:59') and classid in (10) order by newstime desc limit 10

评论已关闭