PDA

View Full Version : Total number of links


imagis
05-24-2007, 02:21 PM
I want to show on very page TOTAL (not category based) number of links.

I know Smarty so i can add into templates but how i can get total number of links into directory ?

Thanks

Dave Baker
05-24-2007, 04:01 PM
***Open index.php and find code***

/** get related categories **/
if ($config->get('related'))
{
$related_categories = $Category->getRelated($id);
$related_categories = $related_categories ? $gDirLayout->print_categories($related_categories) : '';
$gDirSmarty->assign_by_ref('related_categories', $related_categories);
}

***Below add***

$total_num_category = $Category->row("*","`id`='0' and status='active'");
$gDirSmarty->assign('total_num_links', $total_num_category['num_all_links']);

***Save changes***
In the template files you can use the {$total_num_links} variable.

imagis
05-24-2007, 04:28 PM
Thanks.

I am wondering, is not much easier to add all those questions and replies as a FAQ (categorized) on site ? Or even on a eSynd installation.

I mean you guys spending lot of time replying on forums. Is good, but with an online FAQ will be much easier for all i guess...

This doesn't means forum is not useful, i just think is harder to search answers by searching here than looking over a categorized FAQ. ANd for you less time spent on support.

Dave Baker
05-24-2007, 05:33 PM
We already have the Knowledgebase (http://www.esyndicat.com/support/desk/index.php?_m=knowledgebase&_a=view) and we fill it up with the most frequent problems and aspire to build up an useful section for frequently asked questions.
Also we're preparing our manual, and I believe that it will be ready soon. :)