I found this and suddenly realized that I didn't have to traverse the umbraco.config xml to find what I needed.
A great relief when I had to produce lists of 2 preceding events and 2 upcoming events in a list, picked from a mix of single and recurring events, and supplied with other properties from the event document page.
PD Calendar... Get Next Recurrence!
This was really getting me for awhile... How to get the next recurrence of an event that uses the PDCalendar package. Well, here it is:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:stylesheet [ <!ENTITY nbsp " "> ]>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxml="urn:schemas-microsoft-com:xslt"
xmlns:exslt="urn:Exslt.ExsltCommon"
xmlns:date="urn:Exslt.ExsltDatesAndTimes"
xmlns:umbraco.library="urn:umbraco.library"
xmlns:pdcalendar ="urn:pdcalendar"
exclude-result-prefixes="msxml exslt date umbraco.library pdcalendar">
<xsl:output method="xml" omit-xml-declaration="yes"/>
<xsl:variable name="messages" select="pdcalendar:GenerateDates('2009-1-1','2012-12-31','eventDate')" />
<xsl:param name="currentPage"/>
<xsl:param name="eventID" select="/macro/eventID"/>
<xsl:template match="/">
<xsl:for-each select="$messages/node[child::*/@id=$eventID][1]">
<xsl:if test="count(.) > 0">
<xsl:value-of select="umbraco.library:LongDate(@date)"/>
</xsl:if>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
I found this and suddenly realized that I didn't have to traverse the umbraco.config xml to find what I needed.
A great relief when I had to produce lists of 2 preceding events and 2 upcoming events in a list, picked from a mix of single and recurring events, and supplied with other properties from the event document page.
Thanks for sharing!
is working on a reply...