SharePoint - Custom Dataview - Link Display Issues
I have a custom SharePoint page with multiple data. Dataviews essentially filters documents that match certain criteria from a document library and displays a link to the document along with some other metadata.
The problem is that when the document has one quote in the title, the character appears as & # 39; and cancellation of the link. This is the code in my custom page showing an invalid link.
<A onfocus="OnLink(this)" HREF="{@FileRef}" onclick="return DispEx(this,event,'','','','','{ddwrt:ListProperty("DefaultItemOpen")}','{ddwrt:MapToControl("", string())}','{@HTML_x0020_File_x0020_Type}','','{ddwrt:GetUserID('CheckoutUser')}','{$Userid}','{ddwrt:ListProperty("ForceCheckout")}','{$FieldIDA5KNTB}','{ddwrt:CurrentRights()}')"><xsl:value-of select="ddwrt:UrlBaseName(string(@LinkFilename))" /></A>
Does anyone have any thoughts on how I can ensure that the @FileRef variable is correctly encoded before rendering?
Thank you very much in advance:)
+1
source to share