Thursday, December 9, 2010

SharePoint Designer and generate-id

Just wanted to note down a great tip from Marc D Anderson (who derived the idea from a post by Jorge Vasquez) on how to work around the annoyance of SharePoint Designer 2007 inserting generate-id() statements into the ID attributes of HTML tags in customised XSL in SharePoint 2007 or WSS3 pages.

The small steps to applying this fix are as follows:
1. Create an empty dummy variable in the XSL , for example
<xsl:variable name="DummyVar">
2. Append this dummy parameter to any IDs, e.g.
<input id="myid{$DummyVar}" type=......

No comments: