Monday, 24 December 2018

How to enable 'save site as template' in SharePoint Online

Enable save site as template is blocked by default in SharePoint Online. This may because of multiple reasons-
  1.  Scripting is disabled by default so Enabling scripting will enable that option also.
  2. If Scripting is enabled then 'Publishing Feature' should be checked. If publishing feature is enabled then 'Save site as template' will be not available
We can enable Scripting by web admin as well as by PowerShell. Enabling by web admin will take upto 24 hour to enable but by powershell we can do that immediately.

#Config Parameters

$AdminSiteURL="https://xxxxxx-admin.onmicrosoft.com"   
$SiteURL="https://xxxxxx.onmicrosoft.com"

#Get Credentials to connect 

$Cred = Get-Credential


#Connect to SharePoint Online Tenant Admin
Connect-SPOService -URL $AdminSiteURL -Credential $Cred
#Disable DenyAddAndCustomizePages Flag
Set-SPOSite $SiteURL -DenyAddAndCustomizePages $False

No comments:

Post a Comment

Featured post

What is SharePoint?

Microsoft SharePoint is an extensible platform that provides a range of products that can help organizations with solution for a variety...