Removes renderings from an item.
Remove-Rendering -Item <Item> [-DataSource <String>] [-Rendering <Item>] [-Index <Int32>] [-PlaceHolder <String>] [-Parameter <Hashtable>] [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering -Item <Item> -Instance <RenderingDefinition> [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering -Item <Item> -UniqueId <String> [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering -Path <String> [-DataSource <String>] [-Rendering <Item>] [-Index <Int32>] [-PlaceHolder <String>] [-Parameter <Hashtable>] [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering -Path <String> -Instance <RenderingDefinition> [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering -Path <String> -UniqueId <String> [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering [-Id <String>] [-Database <String>] [-DataSource <String>] [-Rendering <Item>] [-Index <Int32>] [-PlaceHolder <String>] [-Parameter <Hashtable>] [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering [-Id <String>] [-Database <String>] -Instance <RenderingDefinition> [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Remove-Rendering [-Id <String>] [-Database <String>] -UniqueId <String> [-Device <DeviceItem>] [-FinalLayout] [-Language <String[]>]
Removes renderings from an item based on a number of qualifying criteria. The search criteria are cumulative and narrowing the search in an "AND" manner.
© 2010-2019 Adam Najmanowicz, Michael West. All rights reserved. Sitecore PowerShell Extensions
The item to be processed.
Aliases | |
---|---|
Required? | true |
Position? | named |
Default Value | |
Accept Pipeline Input? | true (ByValue, ByPropertyName) |
Accept Wildcard Characters? | false |
Path to the item to be processed - can work with Language parameter to narrow the publication scope.
Aliases | |
---|---|
Required? | true |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Id of the item to be processed - can work with Language parameter to narrow the publication scope.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Database containing the item to be processed - can work with Language parameter to narrow the publication scope.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Data source filter - supports wildcards.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Item representing the sublayout/rendering. If matching the rendering will be removed.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Index at which the rendering exists in the layout. The rendering at that index will be removed.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Place holder at which the rendering exists in the layout. Rendering at that placeholder will be removed.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Additional rendering parameter values. If both name and value match - the rendering will be removed. Values support wildcards.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Specific instance of rendering that should be removed. The instance coule earlier be obtained through e.g. use of Get-Rendering.
Aliases | |
---|---|
Required? | true |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
UniqueID of the rendering to be removed. The instance coule earlier be obtained through e.g. use of OD of rendering retrieved with Get-Rendering.
Aliases | |
---|---|
Required? | true |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Device for which the rendering should be removed.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Targets the Final Layout. If not provided, the Shared Layout will be targeted. Applies to Sitecore 8.0 and higher only.
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
Aliases | |
---|---|
Required? | false |
Position? | named |
Default Value | |
Accept Pipeline Input? | false |
Accept Wildcard Characters? | false |
The input type is the type of the objects that you can pipe to the cmdlet.
- Sitecore.Data.Items.Item
The output type is the type of the objects that the cmdlet emits.
- System.Void
Help Author: Adam Najmanowicz, Michael West
remove all renderings for "Default" device
Remove-Rendering -Path master:\content\home -Device (Get-LayoutDevice "Default")
remove all renderings from the "main" placeholder and all of its embedded placeholders.
Remove-Rendering -Path master:\content\home -PlaceHolder "main*"
remove all renderings from the "main" placeholder and all of its embedded placeholders, but only in the "Default" device
Remove-Rendering -Path master:\content\home -PlaceHolder "main*" -Device (Get-LayoutDevice "Default")