power shell脚本将页面库的验证设置应用于我的网站集中的所有站点/子站点/子站点。 [英] power shell script to apply validation settings for pages Library to all sites/sub sites/sub sub sites in my site collection.

查看:49
本文介绍了power shell脚本将页面库的验证设置应用于我的网站集中的所有站点/子站点/子站点。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请提供脚本以将验证设置更新为整个网站集以及子网站和子网站。

Please provide the script to update validation settings to entire site collection as well as subsites and sub sub sites.

此验证应适用于所有网站以检查子网站是否存在?

This validation should apply to all the sites to check if subsite exists?

请提供脚本?

ex:

推荐答案

嗨sudhir,

Hi sudhir,

示例脚本供您参考,应用所有子站点页面库验证(如果有字段"Time Min")和"Time Max"存在于库中:

Sample script for your reference, apply all sub sites Pages library validation if there are fields "Time Min" and "Time Max" existed in the library:

[System.Reflection.Assembly]::Load("Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c")
[System.Reflection.Assembly]::Load("Microsoft.SharePoint.Portal, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c")


siteURL =" http:// sp /"
siteURL = "http://sp/"


spSite = [Microsoft.SharePoint.SPSite](
spSite = [Microsoft.SharePoint.SPSite] (


这篇关于power shell脚本将页面库的验证设置应用于我的网站集中的所有站点/子站点/子站点。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆