Check that the tagged categories are active

This change only includes active categories in the tagging data. If a category is disabled but has sub-categories, the sub-categories are shown. Also, if the disabled category has parent categories, the parents are shown. If the disabled category has both active parent and sub-categories, both are shown leaving out the disabled one from the middle.