I have a layered navigation, and the customer wants to have <select/>
fields instead of a long list of links.
I thought about just changing the template with a observer if the name/id of the filter matches.
Any better ideas or recommendations? Alternatives to changing the template, maybe overwrite/rewrite the block or only change the block class for the two filters?
What event to use for changing the template?
I have then the same problem as here https://stackoverflow.com/questions/14524791/magento-enable-or-disable-a-module-in-code/14529629 because I have an observer who changes layout things. This is only theme relevant. So chechking the theme before running the updates might be a good idea?
Best Answer
Ok, things you need to do: 1. Override the 'catalog/layer_view' block to set your own template. I put my layered nav in the header area as part of a 1 column layout
In that template file you need to specify the overridden template for your individual elements.
Finally, you need to create the drop down filter.phtml. That should be straight forward. This is poorly formatted as I am having trouble with this editor, but the general idea is here. Some Javascript will be needed as well.