Original address: http://www.javaz.cn/site/javaz/site_study/info/2016/48888.html
Project Address: http://www.freeteam.cn/
Infopage
Extracts information paging objects based on parameters.
Parameters |
Description |
SiteID |
ID of the site to which the information belongs |
Channelid |
Information belongs to the column ID |
Channelparid |
Information belongs to the column parent ID |
Num |
Display quantity per page |
Order |
Sort Type 1 headspace valid and descending, publish time descending 2 headspace valid and descending, release time ascending 3 Publish Time Descending 4 Release Time Ascending Starting with the FREECMS 2.5 support 5 headspace valid and descending, row ordinal descending (default) 6 headspace valid and descending, row ordinal ascending 7 Row Ordinal Descending 8 Row ordinal Ascending |
Titlelen |
Caption Display length |
Titlesuffix |
Starting with the Freecms 1.7 support The suffix added when the caption exceeds the display length |
Hot |
Do you want to click Heat in reverse order, 1 is |
DateFormat |
Date format |
Channelpagemark |
Section page identification |
Channelparpagemark |
Parent Column Page Identification |
Img |
Whether to extract only news with pictures 1 is |
Page |
Current first few pages, default is 1 |
Checkopenendtime |
Check public time limit default not check, 1 check |
Newdays |
Within days for the latest |
IsMobile |
Starting with the FREECMS 1.8 support Do you want to extract only the data that allows mobile app access 1 is |
Isfield |
Starting with the FREECMS 2.0 support Whether to query the custom field, 1 is 0 no, tacitly considered to be |
By |
Starting with the FREECMS 2.4 support Sort SQL, set the Order property to expire |
return value |
Description |
Infolist |
Information Object list, type list< data Object info> |
Pager |
Paging objects |
Example 1
Extract information based on site ID and column ID.
< @infoPage siteid= "${site.id}" channelid= "${currchannel.id}" num= "1" page= "${page}"
titlelen= "dateformat=" "YYYY-MM-DD"; Infolist,pager>
<ul>
< #list infolist as info>
<li>
<a href= "${info.pageurl}" target= "_blank" >${info.showtitle}</a>
${INFO.ADDTIMESTR}
</li>
</#list >
</ul>
${PAGER.PAGESTR}
</@infoPage >