开发者

How to know programatically if current page is homepage in Sharepoint 2010?

开发者 https://www.devze.com 2023-03-02 13:44 出处:网络
Is there an easy wa开发者_JS百科y to programmatically know if the current page is a site homepage from a webpart code behind?I think this post might answer your question: https://stackoverflow.com/que

Is there an easy wa开发者_JS百科y to programmatically know if the current page is a site homepage from a webpart code behind?


I think this post might answer your question: https://stackoverflow.com/questions/1649833/replace-the-default-page-in-a-sharepoint-website


I think I've found the answer here: http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spcontextpageinfo.iswebwelcomepage.aspx


I would recommend that you permit the homepage to tell your web part that it is a homepage. Add a parameter to the web part and allow it to be set in the Edit dialog.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号