Hi, I 've got many exposed filters into a view : all I want to do is to show the total number of item per categories that I obtain from a research.
I mean something like this: I have items organized into categories and sub-categories. When I apply a filter, I want this description at the begin of the result list:

i.e.

We have found n°45 items into category "X", subcategory "Y"

where "X" is the main category and "Y" the subcategory , selected in the filter for the research.

I know in Views3 I can show the number of the results by setting "Global:result summary" in the head, but since I want to show the category and the subcategory where the items where found, I think it should be better to insert all this instructions by a code ...

I found following code in order to show the number of results for research of 1 or more records :

<?php
  $view = views_get_current_view();
$count = ( $view->total_rows );
if (count($view->exposed_input)) 
print "$count results per categories";
?>

How can I modify this code in order to show also the category and subcategory from which the results belong ?

Thank you for your help!

Ciao

Comments

nikonvulcano’s picture

Any idea yet ??