[TYPO3-Solr] Excerpt field

Ingo Renner ingo at typo3.org
Tue Mar 20 11:44:55 CET 2012


Am 05.03.12 19:29, schrieb Dmitry Dulepov:

Hi Dmitry,

finally getting back to your issue...

> We have a custom indexer. There are many database fields. We assemble
> the content from them. Part of the content contains information that
> should be searchable but it does not make sense when it is displayed in
> the excerpt. We need to hide it (customer's wish) but it should still be
> indexed.

simply index the data as many times and ways as you need it

* all searchable content into one field which you add to 
plugin.tx_solr.search.query.fields
* content for your excerpt into another field - currently all fields are 
returned with the documents (basically like a SELECT * in SQL)

> May be, we could use an additional dynamic field for the "hidden" data?
> I believe the excerpt is created from the content field only. Is this
> correct?

The automatically created teaser field uses the content field, but you 
can create whatever (dynamic)fields you want/need of course

>> Alternatively you can of course index a separate field exactly to your
>> liking and use that in your template.
>
> But we still need a proper excerpt.

Simply create it yourself to your custom needs and add it to a dynamic 
field.


HTH
Ingo

-- 
Ingo Renner
TYPO3 Core Developer, Release Manager TYPO3 4.2, Admin Google Summer of Code

TYPO3 - Open Source Enterprise Content Management System
http://typo3.org

Apache Solr for TYPO3 -
Open Source Enterprise Search meets Open Source Enterprise CMS
http://www.typo3-solr.com


More information about the TYPO3-project-solr mailing list