Categories are fixed lists of labels that can be assigned to fields in Content Type. Each parent and child category has it's own permissions and therefore is visible or “usable” based upon a content contributor's role permissions. For more information, please refer to our Category Permissions documentation.
To add a new category to the system first click on the Content Types tab and select “Categories” from the drop down menu.
The Category Manager
On the backend of dotCMS lists all Top Level categories currently in the system and allows users to perform the following actions:
Task | Steps |
---|---|
Edit an existing Category |
|
Add a new parent Category |
|
Add child Categories to an existing parent Category |
|
Delete a category |
|
Re-order Categories |
|
Category Properties
All Categories (both top-level Categories and child Categories) has the following properties:
Property | Necessity | Uniqueness | Description |
---|---|---|---|
Category Name | Required | Not Unique | Name of the Category. |
Category Unique Key | Optional | Unique | Value that can be used to reference the category dynamically when searching for content labeled by as specific category type. Note: Since Category Names may not be unique, it is best practice to refer to the Category Unique Key instead of the Name when calling a category name with Velocity code. |
Keywords | Optional | Not Unique | Descriptive keywords assigned to the category for back-end searching. |
Creating Child Categories
After you have saved a parent Category, click the name of that parent Category to begin adding “child” Categories under the parent.
When you create a Category Field in a Content Type, you select a top level Category for that field, and the “child” Categories are the Category selections that content contributors will see when editing content of that Content Type.
Creating Category Hierarchies
You may create any number of levels of Categories under a single Category, creating a hierarchy of Categories as deep as you wish. Whenever a content contributor selects a Category, they may select any child Category or deeper nested Category within the selected top-level Category. For more information, please see the Adding a Category Field to a Content Type documentation.
The example below shows three “child” categories (Consulting, Research, Training), that have been added to the “Product Types” parent category.
Note: Although you can create as many levels of Categories as you wish, for usability purposes it is not recommended to nest Categories more than 3 or 4 levels deep.