# 3.5 Categories

Categories are a way of grouping your posts based on their content within a Survey.

The setup in this guide is demonstrated in the below video as well. You can watch and follow the guide at the same time!

### Video setup guide

{% embed url="<https://www.loom.com/share/80dba3f261704312b0d71119249ab5fa>" %}
Category configuration video
{% endembed %}

### Setup Guide

To access the Categories configuration page,

* On the left hand menu bar, click on ***Settings***

![Settings button in Ushahidi side bar.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/63OMNrCQ8RD76Nf6I6bj/Click_on_settings.png)

* Then, click on ***Categories***.

![Clicking on Settings -> Categories to access category list and actions.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/yziLHdJOwoPn6Bu1dAG0/Updated_Categories.png)

* You’ll be redirected to a page where you can manage categories on your deployment

## 3.5.1 Adding and Configuring Categories <a href="#id-3-5-1-adding-and-configuring-categories" id="id-3-5-1-adding-and-configuring-categories"></a>

Unlike Ushahidi v2.x, your deployment **DOES NOT** come with pre installed/set-up categories. You will need to create this on your new Ushahidi deployment. Categories are now treated as custom fields within a Survey. This gives you the flexibility to add certain categories to some surveys, but not others.

There are two ways to create new categories. First, navigate to ***Settings → Categories***

* Click on the ***Add Category icon as shown below***

![Click on the + yellow circle to add a category.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/zzh3coA23VBUBIoadQA4/Add_category.png)

* In the upper left corner of the category page, you will see the default language that your deployment is currently in.&#x20;

![Click on the + yellow circle to add a category.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/sLj2itM0Bb1ZdqmemEBB/Add_Category_-_Zipcode254.png)

* Add the following details
  * ***Category Name:*** Give your category a name that will appear on your homepage and when users are creating new posts.
  * ***Description:*** You can provide a brief description of what kind of information you will fall under this category
  * ***Child / parent settings***: You can choose to set any category as a “child” to another, creating a hierarchy within the categories themselves, and will reflect this in their positioning on the sidebar.
  * **Default language:** Click on the drop down menu  to select your preferred default language
  * ***Roles***: You can opt to set your category as visible to specific user roles on your deployment here. This list is populated based on custom roles created. More on [Roles here](https://docs.ushahidi.com/platform-user-manual/legacy/4.-managing-people-on-your-deployment/4.1-roles).&#x20;

Once that is done, you can translate the category into other languages.

To do that;

* Click on ***+ Add*** ***translation*** at the upper right-hand corner of the screen.
* A pop-up module will appear on your screen, click on the dropdown menu, and select the language you want to translate to.

![Select a language you want to translate your content to.](https://lh5.googleusercontent.com/AlaFVn58WDLI88ocitXsbA5-S2rQEhZMgDYwADiTfsLw4DvtFgSRzXRKzZeMXUa7v3YQozhSAP55IymMdBwloJzSLv3fkAdu1bXafNOkf66om5eOtUWLNXNYBZFrPh-919_gx2kB)

* Click on Add to finish.
* You will be redirected to a page with the translatable content in the default language and fields where you can add your translations.

![Swahili was the language selected for translation](https://lh6.googleusercontent.com/44crPYiovrY1JTOZOHB8n2cn8bpK632w0Hg1C-K3IhaY83tFeTCpzaPYmnBPlcbmaWGNjCgKuNcPTPUc1G_tEXGMEJZJJBT74FhwNA2bHLZJB9onBHFqLuh3VzMLLSD8ivMUFImK)

* On the empty fields, translate the category name and description details into the chosen language e.g in the above image the default language is English and the added language is Swahili.
* Click Save when all is done to create the category. You can now choose to add this category to any of your Surveys.
* Under the category name, you will see the available languages the category has been translated into.

![All the available languages that the content has been translated to are shown.](https://lh6.googleusercontent.com/r8rmd9iwJEnOOPCyfZMQz4AYyIAXoAEWbIJQ9aL0kybQluYUM4NWeik4C1YrKidWZ-SgcOUZg5q2sP5qe22RW_PoraNoYuI0xLlevXwX0t9jF9uPQ_8Lv-2ABSDutxMabfMlio4b)

\
Add categories as custom fields as you build and edit Surveys. First, navigate to **Settings → Surveys,** and either select the already existing Survey you’d like to edit, or create a new Survey.

* Click on ***Add field*** at the bottom of the survey builder and select \_**Categories** \_from the list of field options&#x20;

![Add categories to a survey.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/6hdKCpR1A9RFcTGYLsDv/Pop_up_2_cat.png)

* Configure the following:
  * ***Name:*** Name or prompt for your survey field
  * ***Show field description:*** Turn this on if you’d like to add a short description or help text to the field
  * ***Which labels should be available:*** Select which categories you’d like to add to the field as options

![Adding a category as a field to a survey. "Add field" modal.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/NykTlCgVNCHwU7qJ4EpR/screen_shot_2017-05-31_at_121456.png)

* Click ***Add & Close*** to save your new categories field
* It will now appear as a custom field with the appropriate categories on your Survey form

## 3.5.2 Editing Categories <a href="#id-3-5-2-editing-categories" id="id-3-5-2-editing-categories"></a>

To edit a category,

* Click on the desired category from the category list page

![Select a category's checkbox from the categories list in the Settings -> Categories page to edit it.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/OgrUH7WnhRzloO0tK6km/Manage_Categories_-_Zipcode254.png)

You’ll get redirected to the ***Edit Category*** page, where you should be able to add/edit details as described in the [adding categories section](#3-5-1-adding-and-configuring-categories) above.

![Save your changes with the yell](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/hg6JcrczulXdhLAWkOfz/Edit_Category_-_Zipcode254.png)

* When done, click on ***Save***, and your changes will reflect shortly.

## 3.5.3 Deleting Categories <a href="#id-3-5-3-deleting-categories" id="id-3-5-3-deleting-categories"></a>

You can delete one or multiple categories at a time.

#### Deleting a category from the category list page

To delete a single category, select the trash icon adjacent to the category.

![Highlighted: trash (delete) button on the right side of the categories list. ](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/CZjgCyncIYwbx6btK69g/Manage_Categories_-_Zipcode254.png)

#### **To delete multiple categories:**

* Tick the checkbox on the left, adjacent to the category/categories you would like to delete from the category list page
* This action will activate the previously inactive ***Delete*** button on top left hand corner of the page. Click on this button to initiate deletion.

![Select the checkboxes in the category list corresponding to categories you wish to delete. Click the trash button on the top menu bar to delete.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/m8dTKHuq9kufkbFDBOfw/Manage_Categories_-_Zipcode254.png)

#### Deleting a category from the category edit page:

* Click on the ***Delete Category*** button

![DELETE CATEGORY button on the bottom of the edit page.](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/eFdcAs5v7dfMUMmem6GE/delete_category_edit.png)

* A pop up box will appear on the top of the page, prompting you to confirm whether you would like to delete the category/categories
  * Click on ***Delete*** to delete your category/categories
  * If you’d like to cancel the category deletion process, click on ***Cancel***![](https://content.gitbook.com/content/Cz9dW2l5mK3oBHqv3G0n/blobs/iNGRU6KqYH8IghIRZam3/Confirm_delete_category.png)
