Creating a New Category

Elements (snippets, chunks, plugins, templates, and template variables) can be placed in Categories in MODX revolution. Sometimes, this is done simply to organize them and to reduce clutter in the Element tree. Most MODX Revolution Extras, for example, place all their elements in a Category named after the Extra. Another user of Categories, however, is to control which elements users in a specific User Group can see, and what they can do with the elements they can see. If you want to hide all elements from certain users, the easiest method is to uncheck the element_tree permission in the Policy attached to the appropriate "mgr" Context Access ACL enty. If, however, you only want to hide specific elements (or control what users can do with them), place them in a Category and create a Category Access ACL entry to protect them.

To create a new Category

  1. Click on the Elements tab in the tree at the left in the Manager
  2. Right-click on the "Categories" folder in the Element tree
  3. Select "New Category"
  4. Enter a Name for your new Category
  5. (Optional) Enter a parent Category if you want to have Categories within Categories

Add elements to your New Category in the Element tree by dragging them into the new Category folder you just created. The folder should appear below the Categories folder in the tree. When you drag an element into a Category, a folder for that Category should appear below the main folder for that type of element. If you drag a snippet into a Category, for example, a new Category folder will appear below the Snippets folder and that folder will contain the snippet you categorized.

To uncategorize elements, you can right-click on the Category folder and select "Remove Category". Note that the elements in the Category will not be removed, they will simply have no category. You can recreate the Category later and put the elements back into it if necessary.

Security Resources at Bob's Guides

 

My book, MODX: The Official Guide - Digital Edition is now available here. The paper version of the book is available from Amazon.

If you have the book and would like to download the code, you can find it here.

If you have the book and would like to see the updates and corrections page, you can find it here.

MODX: The Official Guide is 772 pages long and goes far beyond this web site in explaining beginning and advanced MODX techniques. It includes detailed information on:

  • Installing MODX
  • How MODX Works
  • Working with MODX resources and Elements
  • Using Git with MODX
  • Using common MODX add-on components like SPForm, Login, getResources, and FormIt
  • MODX security Permissions
  • Customizing the MODX Manager
  • Using Form Customization
  • Creating Transport Packages
  • MODX and xPDO object methods
  • MODX System Events
  • Using PHP with MODX

Go here for more information about the book.

Thank you for visiting BobsGuides.com

  —  Bob Ray