Add Header
$w = get-spweb http://SharepointWeb
$nav = $w.Navigation.QuickLaunch
$head=$nav|where { $_.Title -eq "Lists" }
$newLink = New-Object Microsoft.SharePoint.Navigation.SPNavigationNode(“Custom
Home", "/Site/SitePages/Home.aspx")
$nav.Add($newLink,$head)
Add Links
$w = get-spweb http://SharepointWeb
$nav = $w.Navigation.QuickLaunch
$head=$nav|where{$_.Title -eq "Custom Header"}
$newLink = new-object Microsoft.SharePoint.Navigation.SPNavigationNode
-argumentlist @("Home", "http://SharepointWeb/SitePages/Home.aspx")
$head.children.AddAsFirst($newLink)
No comments:
Post a Comment