How to use VqMod in Opencart 4? Installation, configuration, and example use.

In the Opencart tutorial, we are showing you how to use VqMod with examples in Opencart, vqmod installation steps, configurations, example and discuss what kind of issues can occur and its solutions. With this installation, you can use the vqmod XML file to override the core file without changing core files.

Looking for OcMod click here.


Installation steps of VqMod for Opencart 4

Following the steps below will install Vqmod for Opencart 4:

  • Before doing anything please back up your OpenCart installation so that you can revert if unexpected results happened.
  • Download the VqMod from the above download button
  • Extract the zip that you download,
  • You will get vqmod folder and readme file and copy the vqmod directory in your OpenCart root directory, alongside the admin, catalog, extension, system, etc. directories.
  • If you’ve renamed your admin directory, you’ll have to do this bit manually for now:
    • Open vqmod/install/index.php and change $admin = ‘admin’; on around line 33 to match your new admin directory name. We have used wpadmin, so that line is $admin=’wpadmin’
    • Open vqmod/pathReplaces.php and change the line you’d add would be:
$replaces[] = array('~^admin\b~', 'wpadmin');


Now, open your website and add /vqmod/install/ at the end of the URL something like If everything is correct, you will get messages like:


vqmod installation

Errors and Solutions:

1. Administrator index.php is not writeable

vqmod issues solution

For this issue, first, check and please make sure you replace your admin folder correctly on the vqmod/install/index.php and vqmod/pathReplaces.php, and then you can check the file permission if your server can write on index.php file.


For this issue also, we need to make sure you replace your admin folder correctly on the vqmod/install/index.php and vqmod/pathReplaces.php

Example use of Vqmod in Opencart 4

Here is one demo XML file in which you show the “Special Offers” links in the main menu. Open the project in your text editor and go to vqmod folder and then the XML folder create a file named speciallink.xml and add the following lines of code:

	<version>OpenCart Version 4</version>
	<author>Rupak Nepali</author>
	<file name="catalog/view/template/common/menu.twig" error="skip">
			<search position="after"><![CDATA[
				<ul class="nav navbar-nav">
				<li class="nav-item"><a class="nav-link" href="index.php?route=product/special">Special Offers</a></li>
Vqmod xml file example for Opencart 4

Once, you add the above code and then refresh the frontend URL, then you will see a menu item added at the beginning of the Opencart top menu.

Special links in the Menu Opencart vqmod example

In this way, you can use VqMod, know how to install vqmod, and its configurations, for example, and learn how to fix issues that may occur. Hope you liked this article, please subscribe to our YouTube Channel for Opencart video tutorials. You can also find us on Webocreation Twitter and Webocreation Facebook. Please let us know if you have any questions or concerns.

Previous articleHow to develop an Opencart 4 custom theme? OpenCart 4 theme development tutorial
Next articleGoogle Sitemap Opencart 4 Module or extension for free


Please enter your comment!
Please enter your name here