在SharePoint Online 2013中使用Powershell使用自定义模板创建SharePoint网站集 [英] Create a SharePoint Site Collection with a custom Template using Powershell in SharePoint Online 2013
问题描述
我的组织有一个要求,我们想要创建一些基本的自定义模板基于Team Online,SharePoint Online 2013(Office 365)中的发布网站.能 我们是否在租用级别应用并激活这些自定义模板?这样,下次租户管理员需要根据自定义模板创建新的网站集时.因此,自定义模板将显示在自定义零件"部分中,它将直接选择 并由租户Admin使用浏览器创建新的网站集.或我们可以在SPO 2013中创建PowerShell脚本的任何其他方式.因此,在激活脚本后,自定义模板将在 新网站集创建的时间.
I had a requirement in my organization that we want to create some basic custom template based on Team Site, Publishing Site in SharePoint Online 2013 (Office 365). Can we apply and activate those custom templates at Tenancy level? So that when next time if Tenant Admin required to create fresh site collection based on the custom Template. So custom template will appear in the custom part section and it will directly select and created the new site collection by the tenant Admin using the browser. Or any other way that we can create a PowerShell script in SPO 2013.So that after the activation of the script the custom template will be available in the template tag section at the time of new site collection creation.
> 谢谢&问候
Rakesh
推荐答案
Rakesh,
Hi Rakesh,
以下PowerShell Tommy供您参考:
The following PowerShell Tommy for your reference:
<#
Before using this script, install the SharePoint Online Client Components SDK
https://www.microsoft.com/en-us/download/details.aspx?id=42038
#>
Set-PSDebug -Strict
Set-StrictMode -Version 2
<#
.Synopsis
Use this script to create site collections in SharePoint Online
.DESCRIPTION
This script supports normal, as well as custom templates
The default template is "STS#0"
.EXAMPLE
CreateSiteCollections -NumberOfSites 5 -Prefix "Custom"
.EXAMPLE
CreateSiteCollections -NumberOfSites 5 -Prefix "Custom" -Suffix "_Portal" -SiteTemplate "BLANKINTERNETCONTAINER#0"
.EXAMPLE
CreateSiteCollections -NumberOfSites 5 -Prefix "Custom" -SiteTemplate "MyTemplate.wsp" -IsCustomTemplate
.FUNCTIONALITY
Create SharePoint Online site collections
#>
function CreateSiteCollections{
[CmdletBinding()]
param(
#security
[string]
Domain ="* domainprefix * .onmicrosoft.com", [string]
Domain = "*domainprefix*.onmicrosoft.com", [string]
UserName =" *您的管理员帐户* @
UserName = "*youradminaccount*@
这篇关于在SharePoint Online 2013中使用Powershell使用自定义模板创建SharePoint网站集的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!