Allow anonymous access to SharePoint application pages in the _layouts directory
Sample Code public partial class ApplicationPage1 : UnsecuredLayoutsPageBase { protected void Page_Load( object sender, EventArgs e) { } } Create the project In Visual Studio 2010, create a new “Empty SharePoint Project” and name it “MyAnonymousWebPages”. Click OK Enter your SharePoint site Select “Deploy as a farm solution” Adding the custom Pages Next, we need to map the ‘layouts’ directory to our project, so our files are deployed there. Right click on the project name ‘MyAnonymousWebPages’ > Add > SharePoint “Layouts” Mapped Folder SharePoint will automatically add a folder under ‘layouts’ with the name of our project. Right click on this folder >Add > New Item > Application Page Name the page “HelloWorld.aspx” Your project should now look like this: Allowing anonymous access So far, we haven’t done anything special. The steps we’ve taken is the basic approach to ...