XSLT Kit
This is an open discussion with 2 replies, filed under XSLT.
Search
Thanks for sharing Nils,
Bookmarked this tread, it will definetly come in handy some day
We just added a new template for relative time distances:
Given a two dates, the template will return strings like "2 years, 7 months and 17 days" or "3 months". The template speaks English and German.
Create an account or sign in to comment.
I'm not sure I ever mentioned this on the forum but maybe some of the following templates will be helpful for others around here:
Johanna and I curate a set of XSLT templates we regularly use for our projects on Github. So far, the kit contains:
timerange
will print out a single time range based on a start and end date andtimeranges
which will create a list of multiple time ranges with custom separators (,
/and
).name
template) or as list of names (using thenames
template).Further more the kit bundles modified versions of Allen's well known ninja technique and Nick's pagination template:
2
, allh1
will become ah3
, allh2
will become ah4
etc.). Also there are prefix and suffix parameters that are added to the first or the last matched element respectively.nav
).