XF 2.2 Filter example

stromb0li

Well-known member
Does anyone have a simple example that demonstrates how Filters are implemented on the public side of templates? I see the forum_filters template, but don't see how that is invoked or rendered on the page.
 
Sorry for newbie question here, but can you explain these two tags?
<xf:contentcheck>
<xf:extension name="filters">

I am returning back the view now via my public controller, but don't see the filter bar rendering on the page. If I navigate directly to /filters, I see the view.
 
To be honest you can pretty much pretend those aren't there. They just allow for different node types to customize or hide the filters entirely. You should likely omit them for your own implementation.
 
Got it working, thank you!

For those that find this; there are three views that compromise of the filter experience.

1) Main view for the page
2) Macro reference for the filters dropdown
3) Macro reference on the view page that handles showing the active filters

The processing of the menu happens in the public controller as a new action called filters. $this->filter can be used to grab the submitted parameters.
 
Back
Top Bottom