I've created multiple custom application pages using VS 2010 and have deployed them to my SharePoint site.
I'm running into an issue when trying to reference these pages by a URL...
If I use http://myserver/sites/mysite/_layouts/MyApp/MyPage.aspx everything works perf开发者_如何学编程ectly, and I can view my pages.
If I use http://myserver/_layouts/MyApp/MyPage.aspx I get a HTTP 404 Not Found error.
Is there a way I can navigate to my custom page by URL without a specific site reference? Everything I've looked at says that I should be able to access this page directly from /_layouts but it doesn't seem to work.
Note: If I look at the folder "C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS\MyApp" on my server, I see all the aspx pages...
Have you tried another browser? I only have this problem using Firefox, Internet Explorer works perfect. Tried this?
Since the page works on one Site Collection but not the other, it seems to indicate a feature scope issue. However, I'm not sure how this would interfere with pages under _layouts
.
Is your application page associated with a Site Collection level (or lower) scoped feature?
If so, is that feature activated on the root Site Collection (http://myserver
in your example)? Activating the feature or expanding its scope may well resolve the problem.
精彩评论