You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Filype Pereira <pe...@gmail.com> on 2011/06/30 00:54:58 UTC

Building a facet search filter frontend in XSLT

Hi all,

I am looking for some help in building a front end facet filter using XSLT.

The code I use is: http://pastebin.com/xVv9La9j

On the image attached, the checkbox should be selected. (You clicked and
submited the facet form. The URL changed)

I can use xsl:if, but there's nothing that I can use on the XML that will
let me test before outputting the input checkbox.

Has anyone done any similar thing?

I haven't seen any examples building a facet search filter frontend in XSLT,
the example.xsl that comes with solr is pretty basic, are there any other
examples in XSLT implementing the facet filters around?

Thanks,

Filype

Re: Building a facet search filter frontend in XSLT

Posted by lee carroll <le...@googlemail.com>.
Hi Filype,

in the response you should have a list of fq arguments something like
<arr name="fq">
<str>field:facetValue</str>
<str>field:FacetValue</str>
</arr>

use this to set your inputs to be selected / checked



On 29 June 2011 23:54, Filype Pereira <pe...@gmail.com> wrote:
> Hi all,
> I am looking for some help in building a front end facet filter using XSLT.
> The code I use is: http://pastebin.com/xVv9La9j
> On the image attached, the checkbox should be selected. (You clicked and
> submited the facet form. The URL changed)
> I can use xsl:if, but there's nothing that I can use on the XML that will
> let me test before outputting the input checkbox.
> Has anyone done any similar thing?
> I haven't seen any examples building a facet search filter frontend in XSLT,
> the example.xsl that comes with solr is pretty basic, are there any other
> examples in XSLT implementing the facet filters around?
> Thanks,
> Filype
>