Digital resources in the Social Sciences and Humanities OpenEdition Our platforms OpenEdition Books OpenEdition Journals Hypotheses Calenda Libraries OpenEdition Freemium Follow us

Technical note: XSLT to number elements consecutively across parent elements

What follows is a solution to an XSLT problem. The problem: in an XML document, we want to number consecutively elements which share a grandparent element, but not parent. The document contains multiple grandparents. In each we want to restart the counter (imagine a book with chapters which have section; we want to number paragraphs …