我在我的 sitecore 网站中集成了 lucene 搜索,该网站在内容树的内容项下还有一个网站。我searchindex.config
在app_congif/include folder
. 我还更改了 lucenesearch 源以获取 siteroot 作为
SiteRoot = database.GetItem("/sitecore/content");
但搜索不起作用。表明:
找不到结果项
这意味着它没有在/Standard_Items/Search_Results
. 这是我的searchindex.config
:
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/">
<sitecore>
<database>
<database id="master">
<Engines.HistoryEngine.Storage>
<obj type="Sitecore.Data.$(database).$(database)HistoryStorage,Sitecore.Kernel">
<param connectionStringName="$(id)"/>
<EntryLifeTime>30.00:00:00</EntryLifeTime>
</obj>
</Engines.HistoryEngine.Storage> <Engines.HistoryEngine.SaveDotNetCallStack>false</Engines.HistoryEngine.SaveDotNetCallStack>
</database>
</database>
<search>
<configuration>
<indexes>
<index id="SearchIndex" type="Sitecore.Search.Index, Sitecore.Kernel">
<param desc="name">$(id)</param>
<param desc="folder">search_index</param>
<Analyzer ref="search/analyzer"/>
<locations hint="list:AddCrawler">
<resources type="Sitecore.Search.Crawlers.DatabaseCrawler, Sitecore.Kernel">
<Database>master</Database>
<Root>/sitecore/content</Root>
<include hint="list:IncludeTemplate">
<template>{2A609D52-7B9F-49F3-83BE-047FD16397A7} </template>
<template>{F98712D8-27DB-4324-82E6-65242F0977F9} </template>
<template>{849CA304-3F51-4FCB-B9B3-2AC7E950B476} </template>
<template>{A87A00B1-E6DB-45AB-8B54-636FEC3B5523} </template>
<template>{52BDB3C4-0585-437C-89AD-6AAC81950633} </template>
</include>
<IndexAllFields>true</IndexAllFields>
<Boost>2.0</Boost>
</resources>
</locations>
</index>
</indexes>
</configuration>
</search>
</sitecore>
</configuration>
这是我的内容树。我想在 sitecore/content/DruBlue 中搜索。
谁能帮帮我吗 ?