Module Dos and Don'ts

This page contains some basic rules for what you should and shouldn't do when writing your modules.

When writing your module, we encourage you to:

  • Call functions in the API.
  • Call documented core functions.
  • Add things such as Admin Boxes and Organizer Panels using TUIX.
  • Add things such as buttons, fields and tabs to existing Admin Boxes, Organizer Panels and the Admin Toolbar using TUIX.
  • Create and use their own tables (so long as they correctly use the provided table prefix).
  • Update data in core CMS tables indirectly, using API functions or documented core functions.
  • Update data in other modules' tables indirectly, using the static calls or Signals provided by the modules.


If possible, you should avoid:

  • Call undocumented functions in the core. (If you do this, then be aware that the functionality of these functions is liable to change from version to version of the CMS without warning or notice.)
  • Directly read data from the core CMS' tables. (The core database structure is often altered slightly with each version of the CMS.)
  • Directly read data from another modules' tables (unless you also wrote that module).
  • Attempt to alter or suppress the functionality of buttons, fields and tabs in TUIX of another module (unless you also wrote that Module).


You should never:

  • Add new TUIX tags without suitably prefixing them to avoid any name clashes. (You should always use your module's class name as a prefix on the highest level of tag you insert.)
  • Change the core CMS' database structure, or another module's database structure.
  • Directly update core CMS tables, or another module's tables (unless you also wrote that module).
  • Anything on this list.