![]() |
![]() | ![]() | ![]() | Altova Mailing List Archives>Archive Index >microsoft.public.xsl Archive Home >Recent entries >Thread Prev - Re: xsl:variables. [Thread Next] Re: xsl:variables.To: NULL Date: 3/28/2008 1:04:00 PM
Guoqi Zheng wrote:
> You are really great. Everything works. However do you mind explaining
> to me what does below code do?
> generate-id() = generate-id(key('by-letter', substring(., 1, 1))[1])
>
> I do not understand what does the generate-id do here? do you mind explain?
That expression is used as a predicate below:
>> <xsl:apply-templates select="item[generate-id() =
>> generate-id(key('by-letter', substring(., 1, 1))[1])]" mode="group">
It ensures that only the first 'item' element in each group formed by
the key named 'by-letter' is processed. Read more about that here:
<URL:http://www.jenitennison.com/xslt/grouping/index.xml>
--
Martin Honnen --- MVP XML
http://JavaScript.FAQTs.com/
| ![]() | ![]() | ![]() |
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | |||||
|
