Collector Configuration
ReferrerCollector
The ReferrerCollector allows you to collect the location of the external webpage that referred the visitor to your site.
To add this collector to your site add the following configuration at /targeting:targeting/targeting:collectors:
<sv:node sv:name="referrer" xmlns:sv="http://www.jcp.org/jcr/sv/1.0"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>targeting:collector</sv:value> </sv:property> <sv:property sv:name="targeting:className" sv:type="String"> <sv:value>com.onehippo.cms7.targeting.collectors.ReferrerCollector </sv:value> </sv:property> </sv:node>
The following additional configuration properties are supported:
Property name | Property type | Default value | Description |
targeting:visitorScope | Boolean | true | Whether to collect only the first visit or update the data on every visit. |
TagsCollector
The TagsCollector allows you to collect keywords defined on properties of the documents viewed.
To add this collector to your site add the following configuration at /targeting:targeting/targeting:collectors:
<sv:node sv:name="tags" xmlns:sv="http://www.jcp.org/jcr/sv/1.0"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>targeting:collector</sv:value> </sv:property> <sv:property sv:name="targeting:className" sv:type="String"> <sv:value>com.onehippo.cms7.targeting.collectors.TagsCollector</sv:value> </sv:property> </sv:node>
The following additional configuration properties are supported:
Property name | Property type | Default value | Description |
targeting:termsProperty | String | hippostd:tags | The property name of the document nodes to collect the tags from. |
SiteSearchKeywordsCollector
This collector allows you to collect the keywords the visitor used to search your site if your site offers such a site search feature.
To add this collector to your site add the following node at /targeting:targeting/targeting:collectors:
<sv:node sv:name="site-search-keywords" xmlns:sv="http://www.jcp.org/jcr/sv/1.0"> <sv:property sv:name="jcr:primaryType" sv:type="Name"> <sv:value>targeting:collector</sv:value> </sv:property> <sv:property sv:name="targeting:className" sv:type="String"> <sv:value> com.onehippo.cms7.targeting.collectors.SiteSearchKeywordsCollector </sv:value> </sv:property> </sv:node>
The following additional configuration properties are supported:
Property name | Property type | Default value | Description |
targeting:queryParameter | String | query | The name of the request parameter that passes the search terms to your site search feature. |