xsl + dropdown list

Feb 27, 2012 at 2:01 PM

is it possible to make it a dropdown list that filters with  href ?FilterField1=Tag&FilterValue1= - i cant seem to figure out the xsl but would be awesome if someone else could give me a hint towards this


<?xml version='1.0' encoding='utf-8'?>
<xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform' xmlns:msxsl='urn:schemas-microsoft-com:xslt' exclude-result-prefixes='msxsl'>
<xsl:output method='html' indent='yes'/>	
<xsl:template name='terms' match='//termset'>		
<xsl:param name='d'/>	
<div id='accordion'>				
<xsl:for-each select='terms/term'>				
<xsl:call-template name='termtemplate'/>			
<xsl:template name ='termtemplate'>		
<xsl:element name='div'>			
<xsl:attribute name='Selected'>padding-left:<xsl:value-of select='count(ancestor::*)*10'/>px;</xsl:attribute>			 
<xsl:element name='a'>            
<xsl:attribute name='href'>?FilterField1=Tag&amp;FilterValue1=<xsl:value-of select='name'/>	
 <xsl:value-of select='name'/>(<xsl:value-of select='itemcount'/>)         
<xsl:for-each select='term'>				
<xsl:call-template name='termtemplate'/>			
i currently use the above - but would like it to be a dropdown list - and found something like

<xsl:template match="Status">
    <select name="status_id">
      <option value=""></option>
      <xsl:for-each select="Option">
        <xsl:if test="value = /Page/Data/Edit/status_id">
          <xsl:attribute name="selected">1</xsl:attribute>
        <xsl:attribute name="value">
          <xsl:value-of select="value" />
        <xsl:value-of select="label" />
but the <option> doesnt give me a dropdown list - so does anyone have some xsl for this webpart that will list it as a dropdownlist? thanx

Feb 27, 2012 at 2:37 PM

and i was thinking about just changing "div" with "select" (well pretty much) this isnt my strong suite though...