Search Setting 'Do not use custom scopes'
#input parameter
if(($siteUrl -eq $null) -or ($siteUrl -eq ""))
{
$siteUrl="https://td_sp_ui/gbp/portal"
}
#code
# check to ensure Microsoft.SharePoint.PowerShell is loaded
$snapin=Get-PSSnapin | Where-Object {
$_.Name -eq 'Microsoft.SharePoint.Powershell'}
if ($snapin -eq $null) {
Write-Host "Loading SharePoint Powershell Snapin"
Add-PSSnapin "Microsoft.SharePoint.Powershell"
}
#Search SEtting on Site collection with $siteUrl - Do not use custom scopes
$web=get-spweb $siteUrl
$web.AllProperties["SRCH_ENH_FTR_URL"]=$null
$web.update()
write-host "Do not use custom scopes setting: OK"
$web.Dispose()