We do the template sometimes need to use the Call column sub-column, the following article will teach you to achieve the purpose, quite simple. The code is as follows:
In < span=""> the call:
{php $j = 1;}
{loop subcat ($parentid) $v}
{PHP if ($v [' type ']!=0) continue;}
[{$v [catname]}]
{/loop}
In < span=""> the call [or 1-level section of the topic page]:
{php $j = 1;} {loop subcat ($catid) $v}
{PHP if ($v [' type ']!=0) continue;}
[{$v [catname]}]
{/loop}
PS: < span=""> when called, you can also call this:
{pc:content action= "category" Catid= "$parentid" num= "siteid=" $siteid "order=" Listorder ASC "}
{Loop $data $r}
{$r [catname]} |
{/loop}
{/PC}
The parameters are shown in the following table:
Field |
type |
Default Value |
Description |
< span=""> |
smallint |
No |
Column ID |
SiteID |
tinyint (3) |
0 |
Site ID |
Module |
varchar (15) |
No |
Module ID |
Type |
tinyint (1) |
1 |
Column type ID |
ModelID |
tinyint (5) |
5 |
Model ID |
ParentID |
smallint (5) |
5 |
Parent column |
Arrparentid |
varchar (255) |
No |
All parent Columns |
Child |
tinyint (1) |
0 |
Sub-column |
Arrchildid |
Mediumtext |
No |
All sub-columns |
CatName |
varchar (30) |
No |
Column Name |
Image |
varchar (100) |
No |
Column pictures |
Description |
Mediumtext |
No |
Column description |
Parentdir |
varchar (100) |
No |
Parent Column Directory |
Catdir |
varchar (30) |
No |
Column Catalogue |
Url |
varchar (100) |
No |
Column links |
Items |
Mediumint (8) |
0 |
Number of column contents |
Hits |
Int (10) |
0 |
Number of clicks |
Setting |
Mediumtext |
No |
Column Settings |
Listorder |
smallint (5) |
0 |
Sort |
Ismenu |
tinyint (1) |
0 |
is displayed |
< span=""> |
tinyint (1) |
0 |
Whether to build to the root directory |
Letter |
varchar (30) |
No |
Section Pinyin |
http://www.bkjia.com/PHPjc/440388.html www.bkjia.com true http://www.bkjia.com/PHPjc/440388.html techarticle We do the template sometimes need to use the Call column sub-column, the following article will teach you to achieve the purpose, quite simple. The code is as follows: in call:!--* Get sub-columns ...