Introduction to the topic tag listsonclass of CMS loop. Listsonclass tags: sys_ForSonclassData format: [listsonclass] topic ID, number of entries displayed, number of headers intercepted, whether to display the data tag (listsonclass) of a column loop subcolumn)
Tag name: data tag of the subloop column (sys_ForSonclassData)
Format: [listsonclass] topic ID, number of entries displayed, number of headers intercepted, whether to display the topic name, Operation type, and template ID. only the title image is displayed, and the number of columns is displayed. [/listsonclass]
Parameter description:
- Topic ID: parent topic ID. a single topic is a parent category ID, and multiple categories are available. ",", and "0" indicates the information of all primary columns.
- Number of Entries: displays the first few records.
- Number of intercepted titles: several characters are intercepted.
- Show column name: 0 is not displayed, 1 is displayed.
- Operation Type: 0-latest columns; 1-popular columns; 2-recommended columns; 3-column comment rankings; 4-column headlines; 5-column download rankings.
- Tag template ID: ID of the tag template used by the tag.
- Show only images with titles: 0 is unlimited. 1 is to show only information with titles.
- Number of displayed columns: 0 is unlimited.
Parameters |
Parameter description |
Topic ID |
Parent topic ID A single parent category ID Multi-category available "," Lattice open '0' indicates the information of all primary columns. |
Number of Entries displayed |
Display the first few records |
Number of intercepted titles |
Several characters are intercepted. |
Show column name? |
0 is not displayed, 1 is displayed |
Operation type |
0: latest topic 1: topic popularity 2: column recommendation 3: column comment ranking 4: topic headlines 5: column download ranking |
Tag template ID |
ID of the tag template used for this tag |
Show only images with titles |
0 is unlimited. 1 is to show only information with titles. |
Show the number of columns |
0 is unlimited |
Display Toutiao operation type |
0: do not display topic headlines 1: topic content overview 2: column recommendation information 3: topic headlines 4: latest topic information |
Number of headers intercepted |
Several characters are intercepted. |
Toutiao.com interceptions |
Several characters are intercepted. |
Toutiao only displays headers. |
0 is unlimited. 1 is to show only information with titles. |
Toutiao's template variables (Used in the page template content of the tag template) |
[! -- Sonclass. id --]: information ID [! -- Sonclass. title --]: information title [! -- Sonclass. oldtitle --]: information title (no words are intercepted) [! -- Sonclass. titlepic --]: Title image [! -- Sonclass. titleurl --]: Information link [! -- Sonclass. text --]: Information Overview |
Example:
[Listsonclass], 0, [/listsonclass] The topic ID is 9. The number of entries displayed is 2. The title is 14 characters in length. Whether to display column name 0 is not displayed The operation type is 0. Template ID is 7 Only the title image is displayed. 0 is not limited. 2 columns are displayed |
How can this program be implemented? You can refer to the following:
[E: loop = {"select classid, classname, classpath from '[! Db. pre!] Enewsclass 'Where bclassid = '$ bclassid' order by 'classid' desc ", 0}]
Fetch1 ("select title, titlepic, smalltext, titleurl, keyboard, groupid, classid, newspath, filename, id from phome_ecms_news where classid =". $ bqr [classid]. "and titlepic! = ''Order by newstime desc limit 1 "); $ commbookurl = sys_ReturnBqTitleLink ($ commbook);?>
>
"> More>
-
">" Width = "pixel PX" height = "85px"/>
-
">
Query ("select title, titlepic, smalltext, titleurl, keyboard, newstime, groupid, classid, newspath, filename, id from phome_ecms_news where classid = ". $ bqr [classid]. "order by newstime desc limit 5"); while ($ r = $ empire-> fetch ($ newbook) {?>
- "Title =" "> ·
[/E: loop]
Listener (listsonclass) label name: the data label of the loop subcolumn (sys_ForSonclassData) format: [listsonclass] topic ID, number of entries displayed, number of headers intercepted, whether to display the column...