Code Blocks not allowed Sharepoint 2010

Posted: Wednesday 5 October 2011 by Khalid Ameerodien in Labels:
0

I came across this on our test environment recently after authenticating. I then done some googling and found a nifty solution to the problem. I added the following to the web.config file and this resolved the error I was receiving.

 


<SharePoint>

<SafeMode MaxControls="200" CallStack="false" DirectFileDependencies="10" TotalFileDependencies="50" AllowPageLevelTrace="false">

<PageParserPaths>

<PageParserPath VirtualPath="~/pages/demo.aspx" CompilationMode="Always" AllowServerSideScript="true" />

<PageParserPath VirtualPath="~/pages/*" CompilationMode="Always" AllowServerSideScript="true" />

</PageParserPaths>

</SafeMode>

0 comments: