xsl-list
[Top] [All Lists]

Re: [xsl] Ignoring quotation marks in grouping and sorting

2019-01-04 12:13:10
On 04.01.2019 19:03, Michele R Combs mrrothen(_at_)syr(_dot_)edu wrote:

I first create a key like so, using translate to lump all titles that start 
with numerals together):

<xsl:key name="letter-group" match="fmp:ROW" 
use="translate(substring(fmp:COL[2]/fmp:DATA,1,1),'abcdefghijklmnopqrstuvwxyz1234567890','ABCDEFGHIJKLMNOPQRSTUVWXYZ##########')"
 />

Then I do a for-each over the keys, sort that subset, and output:

<xsl:for-each select="key('letter-group', substring(fmp:COL[2]/fmp:DATA,1,1))">
    <xsl:sort select="substring(fmp:COL[2]/fmp:DATA,1,1)" />



What I want is this, with the quoted titles sorted into their correct alpha 
location:

Is there a way to do this in XSL 1.1?

Well, which XSLT 1.1 processor is that, does it have any extension function support for easier or more powerful string handling than XPath 1.0 provides?
--~----------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
EasyUnsubscribe: http://lists.mulberrytech.com/unsub/xsl-list/1167547
or by email: xsl-list-unsub(_at_)lists(_dot_)mulberrytech(_dot_)com
--~--

<Prev in Thread] Current Thread [Next in Thread>