Skip to content
  1. Extras
  2. Ace
  3. Quick start

Quick start ​

Step 1. Install ​

  1. Install Ace via Extras → Installer (overview)
  2. Clear the MODX cache
  3. Ensure plugin Ace is active

Step 2. Editor for elements ​

which_element_editor must be Ace.

Open a snippet, chunk, template, or plugin: the code field becomes Ace with highlighting.

Step 3. Code in resources ​

Context values of use_editor and which_editor are respected:

GoalSettings
Ace in content on every resourceuse_editor = No. A textarea with class modx-richtext is replaced too
Ace only on resources without richtextuse_editor = Yes, which_editor empty or Ace, richtext off
TinyMCE / other RTEuse_editor = Yes, which_editor is not Ace, richtext on
Plain textarea without Aceuse_editor = Yes, which_editor is not Ace, richtext off

which_editor = Ace with use_editor on and richtext on does not put Ace on #ta by itself. Details: Integration.

Step 4. Verify ​

  1. Open a snippet: PHP highlighting is on
  2. Press Ctrl+Alt+H: shortcut table
  3. Type getr and Tab: getResources template expands (if ace.snippets is set)

Checklist ​

Next steps ​