Domanda

How to get all out of the box active features and custom farm solutions features using powershell code in sharepoint 2010 and sharepoint 2013.

È stato utile?

Soluzione

To show all the features on the farm listed by display name and sorted use this:

`Get-SPFeature | Sort -Property DisplayName'

To see all features for a Web Application:

Get-SPFeature -WebApplication http://webapplication

To see all features for a Site Collection:

Get-SPFeature -Site http://sitecollection To see all features for a Site:

Get-SPFeature -Web http://siteurl

SharePoint 2010 Powershell Feature Cmdlets

Here is a snippet of Windows PowerShell code to list all the activated Features for a site collection (SPSite):

Get-SPSite http://sharepoint2010 | % {

    $results = @()

    Get-SPFeature -Site $_ -Limit All | % {

    $feature = $_; 
        $featuresDefn = (Get-SPFarm).FeatureDefinitions[$_.ID]; 
        $cc = [System.Globalization.CultureInfo]::CurrentCulture;

        $obj = New-Object PSObject;
        $obj | Add-Member NoteProperty  Title  $($featuresDefn.GetTitle($cc));
        $obj | Add-Member NoteProperty  Hidden $($feature.Hidden);

        $results += $obj;
    }
    $results | FT -auto;
}

http://blogs.msdn.com/b/josrod/archive/2013/01/04/powershell-to-list-activated-features-for-a-site-and-web.aspx

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a sharepoint.stackexchange
scroll top