Translate

Tuesday, August 12, 2014

Poweshell - Get the list of all template files or layout pages

Not interested in writing big story for small things  :)

List all the template files for given content SharePoint content database -

stsadm.exe -o enumallwebs -databasename <contentdbname>  > c:\template.txt

=====================================
List all page layouts -

$web = get-spweb http://yoursite
$pubWeb = [Microsoft.SharePoint.Publishing.PublishingWeb]::GetPublishingWeb($web)
$pubWeb.GetAvailablePageLayouts() | select Name

No comments:

Post a Comment