Opencart is a complete basic solution for starting an online store. It comes with a very nice Bootstrap based theme that covers all basic needs and is simple to understand.
However its not all of the times a Business has requirements all covered by opencart default features. Many times store owners need to customize the store according to their line of business.
So In this post we will guide store owners on how they can customize the store without breaking it and without making it unstable.
Chances of Instability in Opencart
Many experts have an opinion about opencart that third party plugins and developers work can make Opencart unstable and can take it to a position where you can’t restore or uninstall the changes done.
This is true as your developer can work and modify the original files that can lead to instability. Similarly there is no complete uninstall process that can undo the db changes or restore the overwritten files.
So In this situation your store has a high chance of getting unstable and lead to conflicts with other extensions.
Possible ways to customize Opencart store
There are number of ways you can customize store without making it unstable and having the control to disable or uninstall a customization.
1. Always use Opencart OCMOD Extensions
Opencart introduced OCMOD system , a way to modify the functionality and code from core files without actually changing the framework core files. Using ocmod standard, developer write changes in an xml file and combine it with new files to use for any customization and zip it as *.ocmod.zip or *.ocmod.xml .
This is installed through extension installer that comes in default Opencart and it can be uninstalled by going to list of Modifications and deleting any particular ocmod extension and refreshing the modifications.
If your customization is based on additions not modification then best way is to have modules developed and uploaded via extension installer.
Modules are embedded in layout at top , bottom , left or right of any layout of OpenCart like product page, category page and homepage.
Modules can be installed and uninstalled, also it can be enabled and disabled anytime from back-end.
If you need to change look and feel of the website , the best way is to create a new theme instead of modifying the default theme. Get a completely new theme or just copy the default theme and rename and make changes to the copy of theme files.
OpenCart support third party themes , all required is to follow the theme structure and upload it in catalog / view /theme folder.
After adding files you will notice OpenCart admin will pickup the theme and will allow you to customize the theme settings in admin panel for your new theme, it includes image sizes in product page, category page and search pages and a lot of other settings.
So theme can also be enabled and disabled and it will revert back to original theme.
4. OpenCart Event Based Functions
Recently OpenCart introduced trigger functions similar to filter in WordPress. You can alter the default functionality by introducing your own functions that will trigger either before or after an OpenCart function executes. In this way your function have the power to alter the functionality and you have the power to install and uninstall the code and get your store back to its previous state without getting unstable.
Following the above mentioned methods to customize your store you have the power to install and uninstall , disable and enable customization and it gives you power to restore your store to default if anything doesn’t suits you.
However there is still chance of getting unexpected behaviors. Our Next post will uncover the reason behind unexpected, mysterious and random behavior after customization.
We will update this post with link to next post soon.
iextendlabs.com are highly experienced in custom OpenCart development. We are also top OpenCart extension developers at OpenCart market place. Also OpenCart trainers at YouTube.We
Dedicated team, competitive price and timely delivery promised.
Please feel free to reach out so that we can see if we are good fit for each other and we guarantee to deliver more than your expectations.