Unable to create publishing pages in the pages library in SharePoint 2013


Reproduction Steps:
1) Browse to: https://contoso.com/site/myteam
2) site Actions
3) View All Site Content
4) Pages
5) Library Tools > Documents
6) New Document
7) Page
8) Get an error message saying:
An unexpected error has occurred.
Troubleshoot issues with Microsoft SharePoint Foundation.
Correlation ID: 5a3ab0c7-9b95-4c20-a5a7-04637fe0a120
Date and Time: 2013/12/04 04:19:04 PM
When you pull the ULS logs you see:
Microsoft.SharePoint.Publishing.InvalidPublishingWebException: The site is not valid. The ‘Pages’ document library is missing.
at Microsoft.SharePoint.Publishing.PublishingWeb.GetPublishingListWithCleanup(PublishingListType list, Boolean throwExceptionOnInvalidWeb)
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.BasePageSettingsPage.get_PageListRoot()
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.BasePageSettingsPage.SetParentUrlLabel()
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.BasePageSettingsPage.LoadValues()
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.CreatePagePage.LoadValues()
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.BasePageSettingsPage.OnLoad(EventArgs e)
at Microsoft.SharePoint.Publishing.Internal.CodeBehind.CreatePagePage.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Resolution:
Get customer permission to disable publishing at the Site and Web level then run the following:
Disable-SPFeature –identity “publishingweb” -URL “https://contoso.com/site/myteam” -force
Disable-SPFeature –identity “PublishingLayouts” -URL “https://contoso.com/site/myteam” -force
Disable-SPFeature –identity “Publishing” -URL “https://contoso.com/site/myteam” -force
Disable-SPFeature –identity “PublishingResources” -URL “https://contoso.com/site/myteam” -force
Disable-SPFeature –identity “publishingSite” -URL “https://contoso.com/site/myteam” -force
Confirm that publishing is not active on the Site Collection or Site Level through the UI.
Next we need to allow the Pages library to be deleted by running the following PowerShell script:
$web = Get-SPWeb “https://contoso.com/site/myteam”
$list = $web.Lists[“Pages”]
$list.AllowDeletion = $True
$list.Update()
View All Site Content > Pages > Library Settings > Delete this document library
$web = Get-SPWeb “https://contoso.com/site/myteam”
$list = $web.Lists[“Images”]
$list.AllowDeletion = $True
$list.Update()
View All Site Content > Images> Library Settings > Delete this document library
Enable-SPFeature –identity “publishingSite” -URL “https://contoso.com/site/myteam” -force
Enable-SPFeature –identity “PublishingResources” -URL “https://contoso.com/site/myteam” -force
Enable-SPFeature –identity “Publishing” -URL “https://contoso.com/site/myteam” -force
Enable-SPFeature –identity “PublishingLayouts” -URL “https://contoso.com/site/myteam” -force
Enable-SPFeature –identity “publishingweb” -URL “https://contoso.com/site/myteam” -force
Confirm the issue is now resolved by trying to create a publishing page in the Pages library.

Comments

Popular Posts

SharePoint Interview Questions and Answers

Download Infopath Form Templates

How to get current logged user information using JavaScript ?

Steps to set Form based authentication (FBA) for SharePoint 2010

SharePoint Interview Questions and Answers II

Get List Items - JavaScript

Change Language for current user with JSOM in SharePoint Online

Cross Site List Rollup Web Part for SharePoint 2010

Hide Recently Modified Items

SharePoint 2010 CSS Chart