If a sharepoint site can not be accessed through browser for some reason, the easiest way to reset site navigation to default settings is by using powershell script like so:
References:
https://jespermchristensen.wordpress.com/2013/01/16/set-sharepoint-2013-navigation-settings-from-powershell/
http://sharepoint.stackexchange.com/questions/29449/powershell-script-to-update-navigation-globalincludesubsites-not-applying-change
https://social.technet.microsoft.com/Forums/office/en-US/6b9e8542-a410-4c6f-89a0-532b0a0e831a/powershell-script-to-set-current-navigation-in-navigation-settings?forum=sharepointadmin
https://social.msdn.microsoft.com/Forums/en-US/2f6aec24-0117-4f58-a82d-115f3ce29c6b/restore-managed-navigation-enabled-site-collection-in-a-new-sharepoint-farm?forum=sharepointdevelopment
Write-Host -ForegroundColor
White "Set
the SharePoint 2010 and 2013 Navigation Settings on Sites"
#Set the Site Collection
$SPSite = Get-SPSite -Identity "http://siteurl/"
#Go through each site in the Site Collection
foreach ($SPWeb
in $SPSite.AllWebs)
{
$navSettings
= New-Object
Microsoft.SharePoint.Publishing.Navigation.WebNavigationSettings($SPWeb)
$navSettings.ResetToDefaults();
$navSettings.GlobalNavigation.Source
= 1
$navSettings.Update()
Write-Host "Navigation updated successfully for site $url"
}
https://jespermchristensen.wordpress.com/2013/01/16/set-sharepoint-2013-navigation-settings-from-powershell/
http://sharepoint.stackexchange.com/questions/29449/powershell-script-to-update-navigation-globalincludesubsites-not-applying-change
https://social.technet.microsoft.com/Forums/office/en-US/6b9e8542-a410-4c6f-89a0-532b0a0e831a/powershell-script-to-set-current-navigation-in-navigation-settings?forum=sharepointadmin
https://social.msdn.microsoft.com/Forums/en-US/2f6aec24-0117-4f58-a82d-115f3ce29c6b/restore-managed-navigation-enabled-site-collection-in-a-new-sharepoint-farm?forum=sharepointdevelopment
No comments:
Post a Comment