Adobe COLDFUSION 9 Manual page 498

Developing applications
Hide thumbs Also See for COLDFUSION 9:
Table of Contents

Advertisement

DEVELOPING COLDFUSION 9 APPLICATIONS
Accessing and Using Data
2
Index the collection, specifying the
For more information on indexing Verity collections with support for categories, see
contain
categories" on page 493.
3
Create a search page that lets users search within the categories that you created.
Create a search page using the
searches to the specified category and, if specified, its hierarchical tree.
For more information on searching Verity collections with support for categories, see
contain
categories" on page 494.
Creating collections with support for categories
You can either select Enable Category Support from the ColdFusion Administrator, or write a
uses the
attribute. By enabling category support, you create a collection that contains a Verity Parametric
category
Index (PI).
<cfcollection
action = "action"
collection = "collectionName"
path = "path_to_verity_collection"
language = "English"
categories = "yes">
For more information on using the
in the CFML Reference.
cfcollection
Indexing collections that contain categories
When you index a collection with support for categories enabled, do the following:
• Specify a category name using the
category so that users can specify searches on the documents that the collection contains. For example, you create
five categories named taste, touch, sight, sound, and smell. When performing a search, users could select from either
a pop-up menu or check box to search within one or more of the categories, thereby limiting their search within a
given range of topics.
<cfindex collection="#Form.IndexColl#"
action="update"
extensions=".htm, .html, .xls, .txt, .mif, .doc, .pdf"
key="#Form.IndexDir#"
type="path"
urlpath="#Form.urlPrefix#"
recurse="Yes"
language="English"
category="taste, touch, sight, sound, smell">
• Specify a hierarchical document tree (like a file system tree) within which you can limit searches, when you use the
attribute. With the
categoryTree
contained within the specified path.
To use the
categoryTree
and separating them using forward slashes (/). The tree structure that you specify in a search is the root of the
document tree from which you want the search to begin. The
end of the returned value (as it does when specifying the
Note: You can specify only a single category tree.
and
category
categoryTree
tag that lets users more easily search for information by restricting
cfsearch
tag to create Verity collections with support for categories, see
cfcollection
attribute. The name (or names) that you provide identifies the
category
attribute enabled, ColdFusion limits searches to documents
categoryTree
attribute, you specify a hierarchical document tree by listing each category as a string,
Last updated 8/5/2010
attributes appropriate to the collection.
attribute appends directory names to the
type=path
attribute).
urlpath
"Indexing collections that
"Searching collections that
tag that
cfcollection
493

Advertisement

Table of Contents
loading

Table of Contents