Ajouter un emplacement de recherche Intranet principal
Add primary intranet search location
Explication
L’activation de cette stratégie permet d’ajouter un emplacement de recherche intranet principal dans Windows Desktop Search. Ce texte doit avoir la valeur suivante :
nom,url
Par exemple :
Intranet,http://intranetsearch.aspx?k=$w
Vous devez indiquer les éléments suivants :
1) Nom du périmètre, tel que 'Intranet'.
2) URL du service de recherche. Utilisez $w à la place du mot recherché pour l’URL du service de recherche.
Si votre service de recherche intranet est SharePoint Portal Server, votre requête doit ressembler à ce qui suit :
http://nom_site/Search.aspx?k=$w
Si votre service de recherche intranet est Windows SharePoint Services (WSS), la requête doit ressembler à ce qui suit, où XXXX correspond à l’ID des paramètres régionaux de votre service WSS. Par exemple, l’ID des paramètres régionaux français est 1036.
http://nom_site/_layouts/XXXX/searchresults.aspx?SearchString=$w
Cette action ajoute un emplacement de recherche intranet aux éléments suivants :
1) barre de recherche WDS
2) zone des résultats Desktop Search
3) zone de recherche WDS du Compagnon de recherche
Enabling this policy allows you to add a primary intranet search location within Windows Desktop Search. The value of this text should be:
name,url
For example:
Intranet,http://intranetsearch.aspx?k=$w
You must provide the following:
1) A name for the scope, such as 'Intranet'.
2) The URL to the search service. Use $w in place of the query term for the search service URL.
If your intranet search service is SharePoint Portal Server, your query should resemble the following:
http://sitename/Search.aspx?k=$w
If your intranet search service is Windows SharePoint Services (WSS), the query should resemble the following, where XXXX is the locale ID of your WSS Service. For example, the English locale ID is 1033.
http://sitename/_layouts/XXXX/searchresults.aspx?SearchString=$w
This adds intranet search location to:
1) The Windows Deskbar
2) The Desktop Search results search box
3) The WDS search box in Search Companion
Registre
HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Windows Search- Nom de la valeur
- non défini dans l'ADMX
Valeurs d'activation / désactivation : non défini dans l'ADMX (voir les options ci-dessous).
PowerShell
Commandes PowerShell qui écrivent dans le registre ce que la stratégie écrirait. Les valeurs entre chevrons (<…>) sont à remplacer.
Écrire directement dans le registre contourne la stratégie de groupe : si une GPO gère cette valeur, elle sera réécrite au prochain gpupdate ; sinon la valeur reste en place (effet « tatouage »). Préférez une GPO ou, en local, LGPO.exe. Exécutez PowerShell en administrateur pour HKLM. Certaines stratégies demandent un redémarrage ou gpupdate /force.
Activer
# Activer : Search/AddPrimaryIntranetSearchScope
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Url de la zone de recherche Intranet
Set-ItemProperty -Path $k -Name 'PrimaryIntranetSearchScopeUrl' -Value '<valeur>' -Type StringDésactiver
# Désactiver : Search/AddPrimaryIntranetSearchScope
# Aucune valeur n'est écrite à l'état « Désactivé » (rien de défini dans l'ADMX)Revenir à « Non configuré »
# Revenir à « Non configuré » : Search/AddPrimaryIntranetSearchScope
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\Windows Search'
Remove-ItemProperty -Path $k -Name 'PrimaryIntranetSearchScopeUrl' -ErrorAction SilentlyContinueOptions (1)
| Libellé | Contrôle | Valeur de registre | Type REG | Contraintes / détails |
|---|---|---|---|---|
| Url de la zone de recherche IntranetIntranet Search Scope UrlPrimaryIntranetSearchScopeUrl | Zone de textetext | PrimaryIntranetSearchScopeUrl | REG_SZ |