[HOW TO] Add Filter product with drop menu

Hi,



it’s my first tutoriel, please be indulgent :slight_smile:



Objective : use drop down to show the product filter in category

Warning : this add function only to display filter in category page because i use an smarty capture.

Version : 2.1.2


  1. Put this file in your skins base :


[QUOTE]

skins/(your skin)/customer/blocks/product_filters_dropdown.tpl

[/QUOTE]



2. Modify structure.php


[QUOTE]

schemas/block_manager/structure.php

[/QUOTE]



Add this code

```php

// ajout du menu deroulant 18-11-2010

‘blocks/product_filters_dropdown.tpl’ => array (

‘conditions’ => array (

‘fillings’ => array (‘dynamic’)

),

),

```



at 445 line just after



```php

‘appearances’ => array (

‘blocks/product_filters.tpl’ => array (

‘conditions’ => array (

‘fillings’ => array (‘dynamic’)

),

),

```



3. After create 3 variables in your langage :



dropdown = Drop Down

prev_advanced = Search advanced

reset_more = all results



4. Put this code in your view/categories/view.tpl where you want display filter product





```php

{$smarty.capture.bloc_filtre_produit}

```





5. Clear cache, delete /var/cache and /var/compiled

product_filters_dropdown.zip

Merci beaucoup! One missing language variable I noticed: all_filters