Structure Your Content with Categories

Thank you for your contribution: 

Joomla! articles can be categorized. Generally spoken, categorization is the process of recognizing, differentiating and understanding something through abstraction. This may sound rather complicated but proves very useful when managing several articles.

Joomla! offers the possibility of creating as many categories as you wish. It is possible to build nested categories and an article can be related to one of these categories.

Newspapers, for example, use categories to better differentiate between their articles. Here is an example from a Joomla! template (Figure 1).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 1: Gavick Template December 2009

They are using the category World News and under this category there are additional categories like Politics, World, War, Disasters and more. Sometimes two levels are sufficient like in this example; sometimes you may need more. In Joomla! 1.5 it was not possible to have more than two levels. With Joomla! 1.7 you can have as many levels as you want. Joomla! no longer has sections - only categories.

In the Category Manager (Administration → Content Category Manager), you can manage your category tree and filter up to 10 levels (Figure 2).

cocoate.com/node/5703

Figure 2: Category Manager

Like an article, a category consists of a title, a description and many other attributes and options. It can have an additonal image that can be used in different layouts. The image can be selected in the basic settings. A category can also contain images in the description (Figure 3).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 3: Category Edit Form

When you access your Joomla! website you can see exactly these categories in the example data. The navigation uses links to the categories to show all the articles and sub categories (Figure 4). Even the breadcrumb navigation reflects this structure.

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 4: Categories as menu links on the website

In the Menu Manager (Administration Menu About Joomla!), you can see these menu items, which link to the articles in a category (Figure 5).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 5: Categories as menu links on the website

You can choose from different layouts for the articles. In Figure 5 you can see which layout is used for which link. You can select the layout in the edit form of a menu item (Figure 6).

Possible layouts:

  • a list of all categories
  • a blog layout (like on the frontpage)
  • a category list

Depending on the layout you have plenty of options to configure the appearance and behavior of sub categories and articles.

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 6: Category layouts

A list of all categories

This layout lists all the sub categories from one chosen category (Figure 7).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 7: Layout All Categories

In this case the category description from the top level category Extensions is shown. One level of sub categories with their descriptions is also shown on the page, even empty categories. The articles in the top level category are hidden. Example: Administration Menus About Joomla! Using Extensions → Edit.

A blog layout (like on the frontpage)

The blog layout lists all the articles from one chosen category (Figure 8).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 8: Layout Blog

In this case the category description from the category Components is shown. All the articles related to Components are shown with their teaser text in one column. More columns are also possible. The first seven articles in the top level category are hidden. Example: Administration -> Menus -> Components -> Edit (Figure 9).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 9: Layout Blog settings

A category list

The category list layout lists all the articles from one chosen category in a table structure (Figure 10).

Joomla! 1.6 cocoate.com/node/5703
Joomla! 1.7 cocoate.com/node/8569

Figure 10: Layout Category List

In this case the category description from the category named Joomla! is shown. All the articles related to Joomla! are shown in a configurable table. You can choose to have parts of the table hidden and various sorting options are available. Example: Administration Menus Components Article Category list Edit.

Conclusion

The category system introduced is very powerful and easy to use. You can easily structure your entire website by using a set of nested categories in a very user-friendly way. One article can be assigned to one category.

Comments

I want to see a list of articles links with under a sub-category while showing all subcategories.