SharePoint – CQWP – XSLT in ItemStyle to Format Created Date

The goal is to display the created date with the full month and day:

Add the following namespace attribute to the root xsl:stylesheet element in ItemStyle:

xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime"

Create an xsl:variable element:

<xsl:variable name="Created">
<xsl:value-of select="ddwrt:FormatDateTime(string(@Created) ,1033 ,'MMMM dd')" />
</xsl:variable>

Use the variable:

<xsl:value-of select="$Created"/>

Written by Paul

With 10 years of software development and support experience in the information technology industry, Paul has a proven track record in delivering swift, accurate results on multiple client engagements. He has developed cutting-edge web and client/server applications, E-Commerce customizations, and industry-specific solutions for clients. Currently working at the Government of...
Read more

Leave a Reply

-->
%d bloggers like this: