1

Is there a way to get the language code of a site collection using powershell?

4

Use SPWeb.Language Property:

if ((Get-PSSnapin -Name Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue) -eq $null)
{
    Add-PsSnapin Microsoft.SharePoint.PowerShell
}


$SiteUrl = "http://contoso.intranet.com/"
$site = Get-SPSite $SiteUrl
write-host $site.RootWeb.Language
$site.Dispose()

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.