【问题标题】:SharePoint 2013 custom pagesSharePoint 2013 自定义页面
【发布时间】:2013-04-11 13:15:51
【问题描述】:

我使用 SPWebApplication.UpdateMappedPage 用我的自定义页面更新默认应用程序页面。这似乎适用于 Sharepoint 2010。但是,当我在任何 WebApplication 上使用 SharePoint 2013 中的相同代码时,它不会反映所做的更改。它默认返回特定的 SharePoint 页面(例如:15\layouts\accessdenied.aspx)并且不使用我的自定义页面(例如:15\layouts\custompages\accessdenied.aspx)。

当我使用这个命令时: Get-SPCustomLayoutsPage -Identity "AccessDenied" -WebApplication MyWebApp

它表明 WebApplication 已使用新值更新。

我已按照以下步骤操作:http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.administration.spwebapplication.updatemappedpage.aspx,但不适用于 SharePoint 2013。

这里有什么我遗漏的吗?

【问题讨论】:

  • 尝试编辑清单文件并设置列表完整控件或站点集合完整控件

标签: sharepoint sharepoint-2013


【解决方案1】:

这是一个已确定的问题,有望在未来的修补程序中得到解决。以下是我的发现:http://blog.randomdust.com/index.php/2013/07/custom-access-denied-page-in-sharepoint-2013/

【讨论】:

    【解决方案2】:

    PowerShell 脚本:

    我们在 Web 应用程序中创建并应用了自定义访问被拒绝页面

    1. 在 Layouts 文件夹和 WEB FRONT END 服务器中创建“custompages”文件夹: "c:\Program files\Common Files\Microsoft Shared\Web Server Extensions\
      15\TEMPLATE\LAYOUTS\custompages\Accessdeniederror.html"

    2. 运行 PowerShell 命令:
      Set-SPCustomLayoutsPage –Identity "AccessDenied"
      –RelativePath "/_layouts/15/custompages/Accessdeniederror.html" -WebApplication "http://raghuserver/"

    3. 检查应用的自定义布局页面:
      Get-SPCustomLayoutsPage –WebApplication “http://raghuserver/

    4. 运行 iisreset.exe。

    【讨论】:

      猜你喜欢
      • 2017-10-29
      • 1970-01-01
      • 1970-01-01
      • 2014-09-20
      • 2014-12-10
      • 1970-01-01
      • 2015-01-17
      • 1970-01-01
      • 2021-10-08
      相关资源
      最近更新 更多