Jump to content
WebFlake
  • 0

[Help] How to add description for categories ?


saimi1s

Question

8 answers to this question

Recommended Posts

  • 0

Of course you can edit the boardindextemplate to add descriptions for categories..

find

<foreach loop="categories:$cat_data as $_data">
<if test="cat_has_forums:|:is_array( $_data['forum_data'] ) AND count( $_data['forum_data'] )">
<div id='category_{$_data['cat_data']['id']}' class='category_block block_wrap'>
<h3 class='maintitle'>
<a class='toggle right' href='#' title="{parse expression="sprintf( $this->lang->words['toggle_cat'], IPSText::striptags( IPSText::htmlspecialchars($_data['cat_data']['name'] ) ) )"}">{parse expression="sprintf( $this->lang->words['toggle_cat'], $_data['cat_data']['name'] )"}</a> <a href="{parse url="showforum={$_data['cat_data']['id']}" seotitle="{$_data['cat_data']['name_seo']}" template="showforum" base="public"}" title='{parse expression="sprintf( $this->lang->words['view_cat'], IPSText::striptags( IPSText::htmlspecialchars($_data['cat_data']['name'] ) ) )"}'>{$_data['cat_data']['name']}</a>
</h3>

change to 

<foreach loop="categories:$cat_data as $_data">
<if test="cat_has_forums:|:is_array( $_data['forum_data'] ) AND count( $_data['forum_data'] )">
<div id='category_{$_data['cat_data']['id']}' class='category_block block_wrap'>
<h3 class='maintitle'>
<a class='toggle right' href='#' title="{parse expression="sprintf( $this->lang->words['toggle_cat'], IPSText::striptags( IPSText::htmlspecialchars($_data['cat_data']['name'] ) ) )"}">{parse expression="sprintf( $this->lang->words['toggle_cat'], $_data['cat_data']['name'] )"}</a> <a href="{parse url="showforum={$_data['cat_data']['id']}" seotitle="{$_data['cat_data']['name_seo']}" template="showforum" base="public"}" title='{parse expression="sprintf( $this->lang->words['view_cat'], IPSText::striptags( IPSText::htmlspecialchars($_data['cat_data']['name'] ) ) )"}'>{$_data['cat_data']['name']}</a>
<br>My Cat description here.
</h3>

The easiest way would be to add the description to the language files  something like $this->lang->words['cat10_description'] and create one for each cat replacing the 10 with the cat id number. Then adding  that instead of a bunch of if statements.

  • Upvote 1
Link to comment
Share on other sites

  • 0

Sure Dragonvoid,

 

On ipb you have Categories/Forums/Sub-forums

 

What i'm looking for it's a way to add TEXT DESCRIPTION for CATEGORIES like we do for Forums.

On IPB official website they said that it's not possible..

If you have any solution ?

 

Thks


Or if you can find a way to add text under a CATEGORIE, but different text for each categories

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...