In a SharePoint site collection, Site logo can be easily changed by going to site settings –> Look and Feel –> and click Title, Description and Logo. But if there are multiple sub sites then it going to be a hassle to go to each site and perform this action.
To minimize this effort, we can go with PowerShell cmdlets where a simple script can do the task for us. The PowerShell script is different for both online and on-premise environments. In this blog post I am sharing the PowerShell script which will work for SharePoint on-premise.
Below is the PowerShell which can update site logo for all the sub sites under a site collection, this script has been testing on SharePoint 2010, SharePoint 2013 and SharePoint 2016.
if ((Get-PSSnapin “Microsoft.SharePoint.PowerShell” -ErrorAction SilentlyContinue) -eq $null)
{
Add-PSSnapin “Microsoft.SharePoint.PowerShell”
}
$sitename= “http://Sp2016”
$sitelogo= “/siteAssets/NewLogo.jpg”
$site=new-object Microsoft.SharePoint.SPSite($sitename)foreach($web in $site.Allwebs) {
$web.SiteLogoUrl=$sitelogo
$web.Update()
}
$site.Dispose()
Leave a Reply
You must be logged in to post a comment.
7 replies on “Changing site logo for all sub sites in a Site collection”
Thankfulness to my father who stated to me regarding this webpage, this website is genuinely amazing.
Very descriptive blog, I enjoyed that bit. Will there be a part 2?
Thanks Judi, Yes I have written the part two, please check it at this link: https://mstechtalk.com/changing-site-logo-for-all-sub-sites-in-a-site-collection-for-sharepoint-online-office-365/
I am regular visitor, how are you everybody?
This article posted at this site is in fact fastidious.
Having read this I thought it was really enlightening.
I appreciate you spending some time and energy
to put this information together. I once again find myself spending way too
much time both reading and leaving comments. But so what,
it was still worthwhile!
Oh my goodness! Amazing article dude! Thank you so much, However
I am encountering issues with your RSS. I don’t know the reason why I can’t subscribe to
it. Is there anybody having similar RSS problems? Anyone that knows
the solution will you kindly respond? Thanks!!
Hello everyone, it’s my first go to see at this website, and
paragraph is truly fruitful designed for me, keep
up posting such articles or reviews.