当前位置: 动力学知识库 > 问答 > 编程问答 >

Sharepoint 2010 custom redirect for folder

问题描述:

when I hit my website on the "rootWeb" (mysite.com) address i get redirect to "rootWeb/Pages/Default.aspx"

My company had a exchange web access at "company.com/Exchange2010".
Now since "company.com" is the new sharepoint portal, its a requirement that the exchange access stay the same...
so i created a library called Exchange2010 and inserted the files... but, so it all can work just fine the user has to enter the full url "company.com/Exchange2010/default.asp" (default.asp is a file in the doc library)
Now what I want to change the redirect from "/forms/allfiles.aspx" to "/default.asp"...

how can I do this???

网友答案:

Can you clarify on what you need exactly?

If you create a new site in SharePoint named 'MySpecialFolder', and browse to 'rootWeb/MySpecialFolder', you will be redirected automatically to 'rootWeb/MySpecialFolder/Pages/default.aspx'. This is the OOTB behavior on SharePoint.

If you REALLY want to remove '/Pages', and change 'default.aspx' to 'MyPage.aspx'. You can use the url rewriting module in IIS, which works by matching regular expressions to change the url. This can work, but will take you a lot of time to understand the rewriting module, can cause a lot of side effects, and it is bad to change the way SharePoint works by default.

For what reason do you need that, can you elaborate on the goal to achieve?

网友答案:

i ended up working around it, i created a site collection with explicit inclusion and setted the default page for the site collection my custom page...

its not a beautiful solution... if anyone propose a better one i will mark as answer...

分享给朋友:
您可能感兴趣的文章:
随机阅读: