The form handlers described in this chapter can be used for searching any content indexed by ATG Search. They are not restricted to searching documents created from ATG repository items.

If the documents being searched do represent repository items, each Result object will contain the URL for the corresponding item. You can use the URL to display the repository item. For example:

URL: <c:out value="${result.url}"/>

<dspel:droplet name="/atg/targeting/RepositoryLookup">
   <dsp:param name="url" param="${result.url}"/>
   <dsp:oparam name="output">
     <dsp:valueof param="element.displayName"/>
   </dsp:oparam>
</dspel:droplet>

Note, however, these URLs will not be recognized unless the repository is registered. To register a repository, add it to the list of repositories in the initialRepositories property of the /atg/registry/ContentRepositories component.

 
loading table of contents...