Documentation
Installation instructions
If downloaded package has .ocmod.zip extension, you can install it using Extension Installer. If you see "The directory is not allowed to be written to" error message, download Extension Installer Fix from this page and install it. Then install the main extension.
In any other case or if you want to install it manually, unpack and upload all folders to the root of your store. If there's install.xml file in the package, rename it to extension_name.ocmod.xml, replacing "extension_name" with extension's name, and upload it to "system" folder.
When upgrading from previous version rewrite all existing files. Refresh modifications cache from Extensions -> Modifications page.
Note for OpenCart 2.0.X users
Sometimes OCMod inserts modification in multiple files, which are separated by "|" character in XML-file. On earlier OpenCart 2 versions a comma was used instead. To quickly fix this, open XML file and replace all occurrences of "|" character with "," for "path" attribute in every applicable <file> element. Search for "<file path=" to quickly find and highlight all elements.
Note for OpenCart 2.3 users
On OpenCart 2.3 compatibility code is broken, which may lead to Permission Denied issue, when you access extension settings. To fix this you need to install OpenCart 2.3 Compatibility Fixes extension.
The right sequence of actions is the following:
- Download our purchased (or free) extension, but do not install it yet (uninstall, if already installed).
- Install OpenCart 2.3 Compatibility Fixes extension.
- Refresh modifications cache from Extensions -> Modifications page.
- Go to System -> User Groups and select all access/modify permissions for your group.
- Install our purchased (or free) extension.
If you did everything right, everything will start working properly.
Note for OpenCart 3 users
NOTE: Instructions below are required only if "admin" or "catalog" folders are present in the package!
To install and use extension on OpenCart 3 you need to install OpenCart 3 Compatibility Fixes. It adds backward compatibility with old extension structure plus adds back support for .tpl files and enables automatic template engine detection.
The right sequence of actions is the following:
- Download our purchased (or free) extension, but do not install it yet (uninstall, if already installed).
- Install OpenCart 3 Compatibility Fixes extension.
- Go to Extensions -> Modules section, install and enable Template Switcher.
- Refresh modifications cache from Extensions -> Modifications page.
- Go to System -> User Groups and select all access/modify permissions for your group.
- Install our purchased (or free) extension.
If you did everything right, everything will start working properly.
Permissions
In some cases it is required to manually set permissions for installed extension. To do this go to System -> User Groups, find your group and select access/modify permissions for desired extension. You can find extension in permissions list by folder/filename pair (for example, marketing/acoupon).
Extension Setup
General settings
Every option has a hint with short description of what each option does. Below are more detailed explanation:
- License ID - Your corresponding order ID on our site or opencart.com.
- Autoclear - Set it to Yes, if you want to enable automatic discarding of the incomplete input (default - No).
- Check Version - Automatic extension's version checking.
- Status - Enable or disable extension.
Adding masks
First of all you need to add at least one field mask. Go to extension settings, select Masks tab and add a mask:
- Field - Any field name to apply mask to. Must be a full field name!
- Mask - Desired field mask: a - alpha character (A-Z,a-z), 9 - numeric character (0-9), * - alphanumeric character (A-Z,a-z,0-9), ? - anything after it is considered optional.
- Placeholder - If you are not satisfied with the underscore character as a default placeholder, you may define your own here.
Example:
Field: telephone
Mask: (999) 999-9999? x99999
Placeholder: #
In any form, which contains "telephone" field the following mask will be added: (###) ###-### x#####, where x##### is optional input.
Adding definitions
If your requirements aren't met by the predefined placeholders, you can always add your own. Select Definitions tab from extension settings and add new item:
- Placeholder - Any single character similar to default a, 9 or * characters.
- Regular Expression - Any regular expression to check for desired input.
Example:
Placeholder: h
Regular Expression: [A-Fa-f0-9]
This will allow only hexadecimal characters. Then you can use this definition to mask for something like CSS colors in hex with a mask #hhhhhh.