Solution: How to disable features within ezoe the online editor

Question

How can I disable the table border, table class and table caption fields from displaying?

Answer

These features are built-in to eZ OE by default and must be disabled via custom settings overrides and custom template overrides within your user siteaccess.

Example #1 Disable the table caption feature

To hide the table caption field in your user siteaccess only then edit or create the file in settings/siteaccess/user-siteaccess-directory/content.ini.append.php and It should look like this:

[table]
CustomAttributes[]
CustomAttributes[]=summary
#CustomAttributes[]=caption

Save the settings override file changes and clear ini caches!

Example #2 Disable the table border and class feature

To hide the table border and class fields:

  • Create a template override of this file: extension/ezoe/design/standard/templates/ezoe/tag_table.tpl
  • Edit your template override file: extension/custom-design-extension/design/custom-user-siteacces-design/templates/ezoe/tag_table.tpl
  • Look for this content in the file:
{include uri="design:ezoe/generalattributes.tpl"
             tag_name  = $tag_name
            attributes = hash('width', 'htmlsize',
                                       'border', 'htmlsize',
                                       'class', $class_list
                                      )
}
  • Change the above content to look like this:
{include uri="design:ezoe/generalattributes.tpl"
             tag_name  = $tag_name
             attributes = hash('width', 'htmlsize')}

Save the template override file changes and clear all template caches!

Closing

And your done! These changes have been tested and work well with eZ Publish Community Project 2014.07+. You should have no problems with the example instructions provided above.

It is worth noting that if you make a template override of the above template in the user siteaccess design only then the admin siteaccess can still use these fields and retain full control and flexibility.

This also applies to the setting file change. That can be made in the user siteaccess only as well and retain admin full control.

References