2

I have a sharepoint site. In its IIS directory I've created an aspx file.

When I browse to it using IE - I get a 404.

I'm using it for testing out controls relating to SharePoint.

How can I make the aspx file that I manually created usable? Not 404?

8

The IIS virtual web of a SharePoint site is off limits :-) Anyway pages are picked up by a module that redirects all parsing of pages (simplified).

Depending on versions you have different options.

For SharePoint 2007 we had Site Pages that could be provisioned using the <Module> element, or you could create Application Pages.

Site Pages lives in the root of a given site and can have code behind. A typical use is a page that should only be visible for a given site.

Application Pages lives in a virtual directory, _LAYOUTS and can be accessed farm wide. A typical use is some application that should be made available from all parts of a farm.

Se here how to create an application page for MOSS / WSS3

Here is a primer on how to use code behind in ASP.NET pages in SharePoint 2007

In SharePoint 2010 the story is somewhat the same, except Site Pages have been moved from the root of a site to the SitePages library. A description of the two types of pages can be found here on MSDN.

2

Deploy page to {SharePointHive}\Templates\Layouts, access from browser by url: {site-url}/_layouts/{page}.aspx

0

This may get you close to what you need:

  • Go to site collection in browser
  • Site Actions -> Edit site in sharepoint designer
  • Navigation -> Site Objects -> All Files
  • Right click -> New -> ASPX
  • Add you sharepoint controls
  • Save
  • Test sharepoint controls

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.