Website construction often need to output a column of sub-columns, corresponding to the Sub-column list page also need to output the parent column of the Sub-column list, THINKCMF can output all sub-columns, but not in the Sub-column list page also applicable,
Therefore, you need to complete the requirements by querying the database tables:
<? php $RS = M (' terms ')->where (Array (' term_id ' = + $term _id))->find (); $parent = M (' terms ')->where (Array (' term_id ' = + $RS [' parent '])->find (); ?>
This method finds its parent by querying the terms table, and then outputs the sub-columns,
1 <PHP>2 $term _id= $term _id;3 $terms =sp_get_child_terms ($RS [' parent ']);//Get sub-categorical information4 </PHP>5 <foreachname= "Terms"Item= "Vo">6 {$vo. Name}7 </foreach>
Similarly, you need to query the parent column name:
1 {$parent. Name}
Abstract, the same keyword
THINKCMF Sub-column to get the parent column all sub-columns list