SharePoint Replaceable Tokens Are (Sometimes) Case-Sensitive

By on July 12, 2012,

I noticed an odd thing while working with some JavaScript and Custom Actions in SharePoint 2010…the URL tokens (“~site”, “~sitecollection”, etc.) appear to be case sensitive when used in a ScriptBlock attribute (lower-case works, mixed-case does not) but NOT case sensitive when used in the ScriptSrc attribute.  In other words, “~sitecollection” works in either, but “~SiteCollection” only works in ScriptSrc, not ScriptBlock.

Another of SharePoint’s little quirks…



Tags , ,