Defining Categories and Vocabularies for Content
Using categories, you can group similar assets and organize your content. Along with tags, categories help people find relevant information through search or navigation. For more information about categories in Liferay DXP and the different usage scenarios, see Organizing Content with Categories and Tags.
You can group categories using vocabularies and create a hierarchy using subcategories. Once you create and edit global vocabularies, you can use them in any other site, but they must be edited at the global site.
Only site administrators can manage categories and vocabularies in the Categories panel.
Defining Vocabularies
-
Go to the site where you want to create the vocabulary.
-
Open the Site Menu (
), expand Categorization, and go to Categories.
-
Click New Vocabulary (
).
-
Enter a name for the vocabulary and, optionally, a description.
-
Complete the rest of the category options:
Allow Multiple Categories: Enable this option to use more than one category from the vocabulary to categorize the asset. When disabled, you can use only one category from the vocabulary.
Visibility: See Vocabularies Visibility for more information.
ImportantYou cannot change the visibility after saving the vocabulary.
Associated Asset Type: Select the allowed asset types for applying a category from this vocabulary. Set Required to Yes if you want this type of asset always to have a category.
TipClick Add under the Associated Asset Type section to include more than one asset type.
-
Click Save.
-
To edit an existing vocabulary, click Actions (
) next to the vocabulary name and select Edit.
Defining Categories
You create and manage categories in the Site Menu () → Categorization → Categories panel. You can also create new categories from the Categorization section in the Content Editor, using the Select button for each vocabulary.
The default limit is 150 categories per vocabulary. You can change this limit, but a high number of categories could affect performance, especially in item selectors.
Creating Categories
-
Open the Site Menu (
), expand Categorization, and go to Categories.
-
Under the Vocabularies list, click the vocabulary to add the new category.
-
Click Add Category (
).
-
Enter a name for the category and, optionally, a description.
-
Under the Display Page section, choose a specific display page for the category or use the default one.
NoteDisplay pages for categories are available starting with Liferay DXP 7.4. For more information, read Displaying Categories Using Display Pages.
-
Click Save or Save and Add a New One to add more categories.
-
To edit an existing category, click Actions (
) next to the category’s name → Edit.
Creating Subcategories
You can create a nested hierarchy of categories and subcategories:
-
Open the Site Menu (
), expand Categorization, and go to Categories.
-
Under the Vocabularies list, click the vocabulary you want to modify.
-
Click the category name where you want to create the new subcategory.
-
In the Add New Subcategory screen, enter the subcategory’s name and, optionally, a description.
-
Click Save or Save and Add a New One to add more subcategories.
Moving Categories
You can move a category to a different vocabulary, or as a subcategory in the same vocabulary:
-
Open the Site Menu (
), expand Categorization, and go to Categories.
-
Click Actions (
) next to the category you want to move and select Move.
-
Select the Vocabulary and Category where you want to move the category.
NoteYou can only move a category into a vocabulary of the same visibility type.
Editing Additional Category Properties
After creating a category, you can define these options:
- Details
- Images
- Friendly URL
- Properties
To access these options, click Actions () next to the category you want to modify and select Edit.
Changing the Maximum Number of Categories per Vocabulary
By default, vocabularies can have up to 150 categories, but you can increase this:
A high number of categories may impact performance and load times.
-
Open the Global Menu (
). Navigate to Control Panel → Instance Settings → Assets.
-
Click Categorization in the left navigation. Enter a new maximum value (e.g.
2
) and click Save. -
Upon reaching the maximum value, a message informs users they cannot create more categories.