xsl-list
[Top] [All Lists]

Re: [xsl] Last name first

2012-01-30 11:58:13
Jacob L wrote:

I am using<xsl:stylesheet version="2.0" .If in the input XML file,
the text in the<p>has a name such as

<p>  Aaron S. Williams</p>

and I want the last name to come first, seperated by comma like this

<p>  Williams, Aaron S.</p>

Is it possible using xslt?

Look into xsl:analyze-string http://www.w3.org/TR/xslt20/#analyze-string.
If you need help with precise code then please first explain in more detail whether you expect "p" elements to solely contain names or whether you want to look for names in some more complex content.

--

        Martin Honnen --- MVP Data Platform Development
        http://msmvps.com/blogs/martin_honnen/

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

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