In this article, we describe how to customize a Joomla! category by adding three custom fields.

Structure of a Joomla! category

add_category_menu_linkTo show the structure of a Joomla! category, let click on "Content", "Category Manager" then "Add New Category".
category_formAs you can see in this image, a Joomla! category is essentially (not only) composed of three main fields : "Title", "Parent" and a "Wysiwyg" (acronym for What You See is What You Get) to add description.
Look at how we will customize this structure by adding three custom fields.

How SEBLOD manages a form of Joomla! category

The form above is being built by a "Content Type" called "Category".
To see the structure of this content type, you can:
Fom_Content_Type_Menu_Linkclick on admin menu link "Components" then "SEBLOD 3.x".
seblod_control_panelThe control panel of SEBLOD appears. You should click then on icon "Forms & Content Type",

Fom_Content_Type_Menu_Link_Shortcutclick on admin menu link "Construction" then "Forms & Content Types".
form_content_type_managerIn the "Form & Content Type Manager", you should click on the item "Category"
As you can see in the image below, each field of a form is present on the "Content Type" side. The main important: title, parent and description are marked in yellow in the image.
So, we have the correspondences between:
  • SEBLOD field "Category Title" and the form field "Title"
  • SEBLOD field "Category Parent" and the form field "Parent"
  • SEBLOD field "Category Description" and the form field "Description".
category_ct
Let's look at how to add 3 custom fields to the content type "Category".

Add 3 custom fields, the process

To add 3 custom fields to the "Category" content type, click on button "+" (the button "+" is placed at the right of the "Construction" block). A form in window popup appears add-field-popup-window_in_category_ct
Adding a Text field
add_text_field_in_category_ct_popup_formTo add a "Text" field to the "Category" content type:
  • set a field "Title", for example "My Text Field"
  • set a field "Label", for example "My Text Field"
  • select a field "Type": of course a "Text" option of the Type setting
  • click on button "Save & New" to add the next field.
Adding a "Select Simple" (Dropdown) field
add_dropdown_field_in_category_ct_popup_formTo add a "Select Simple" field to the "Category" content type:
  • set a field "Title", for example "My Dropdown Field"
  • set a field "Label", for example "My Dropdown Field"
  • select a field "Type": of course a "Select Simple" option of the Type setting
  • set "options" to this "Select Simple" field: for example "SEBLOD" and "Joomla!" options.
  • click on button "Save & New" to add the next field.
Adding a Radio field
add_radio_field_in_category_ct_popup_formTo add a Radio field to the "Category" content type:
  • set a field "Title", for example "My Radio Field"
  • set a field "Label", for example "My Radio Field"
  • select a field "Type": of course a "Radio" option of the Type setting
  • set "options" to this "Radio" field: for example "Yes" and "No" options.
  • click on button "Save & Close".
Result after adding fields
After this adding three new lines appears in the "Category" content type (see 3 yellow lines in the following image)category_ct_3_custom_fields
The resulted form after adding this 3 custom fields is illustrated in the following imagecategory_form_after_adding_3_custom_fields