Fix Theme Editor - patch for correct work Theme editor and OCMOD

Fix Theme Editor - patch for correct work Theme editor and OCMOD
Fix Theme Editor - a patch for the correct work of the theme editor in Opencart 3x.
Fixes incorrect work when making changes to the same file simultaneously through the Theme Editor and OCMOD modifiers.

Built-in Theme Editor in Opencart 3x it's a useful, nice, but contains a serious bug:

If you edit the some template file through the Theme Editor, and if the same file will change through the OCMOD system - it will change in the OCMOD cache, but will not be used.
Instead, the file will be used, modified through Theme Editor, without taking its changes through the OCMOD.

I.e. if you use OCMOD, the original template file is changed, without taking into account changes in the theme editor.
But later, when outputting to a template, the file is output directly from Theme Editor, without taking its changes through the OCMOD.

This patch corrects this flaw.
After applying patch, when making changes to the template file via OCMOD - primarily, will be checked for any changes to this file in the theme editor.
And if they are, the modifier will be applied to the already changed file through the Theme Editor.

FEATURES
✔ Actual for OpenCart versions 3020-303x
✔ After each change of template files through Theme Editor you need:
1. Update the modifier cache in Extensions> Modifications
2. Update the Theme cache in Dashboard> Developer Settings
for these changes to take effect
(and the modifiers were applied to the changed version of the template file instead of its original file)
✔ Does not change core files, works through OCMOD

INSTALL
1. Copy the file "__fix_theme_editor.ocmod.xml" into the folder "system" *
2. Refresh the Modifications cache (press Refresh button) in Extensions > Modifications
3. Refresh Theme cache in Dashboard > Developer Settings

* this method is used for correct operation, the patch must be work before of all other modifiers

UNINSTALL
1. Delete the file "__fix_theme_editor.ocmod.xml" from the folder "system"
2. Refresh the Modifications cache (press Refresh button) in Extensions > Modifications
3. Refresh Theme cache in Dashboard > Developer Settings

PLEASE NOTE:
If you don’t understand how the system of OCMOD modifications works in Opencart - don’t use Theme Editor at all.
Remember that changing the template files can lead to problems in the work of modifications for their.

MAY BE INTERESTED:








Download
  • Developed by OpenCart Community
  • Documentation Included

Rating

Compatibility
3.0.2.0, 3.0.3.0, 3.0.3.1, 3.0.3.2

Last Update
28 Oct 2019

Created
17 Feb 2019
282 Downloads
2 Comments
AlexDW
AlexDW
Member since: 27 Oct 2014

View all extensions Get Support