I have been tasked with setting up a calendar on SharePoint 2010 Foundation to record bookings.
I would like to use a custom display form so I can remove and/or reorder the fields. I created a new display form using SharePoint Designer 2010 (Navigated to subsite > Lists and Libraries > myList and clicked New... under Forms section, and chose Display type).
Using the new Display form I have noticed a few bugs/inconsistencies.
First, lookup fields revert to showing raw HTML, rather than a link. I fixed that by adding
disable-output-escaping="yes"
to the xsl tag attributes.
Second, dates seem to show as a full ISO date, rather than a more readable dd/MM/yyyy HH:MM format. I thought I could solve this by adding the code below
<xsl:value-of select="ddwrt:FormatDate(string(@EventDate),2015,5)"/>
In the design view in SharePoint Designer, the desired formatting shows up. However, when I view an item on the site itself (through IE) the field is blank. I cannot work out why Designer shows the correct result, but the site itself does not. I can't even find anyone else online with the same issue. Hence this post.
This image shows the SharePoint Designer 2010 Design view. The Start Time has been formatted using the formula above and displays correctly. The End Time is the default ISO format.
Viewing an event using the custom display form via the site is shown in this image. The formatted date is not displayed at all.
Is there a way of getting the site to properly display the date with the formatting formula applied? Better still, is there a way of customising the display form without these annoying quirks? (Boolean fields showing as 1/0 rather than Yes/No. Recurrence field showing 1/0 rather than the actual recurrence schedule etc).