OpenCart Tips and Tricks · 2 min read · Updated

OpenCart 3 error Warning: You do not have permission to modify the default store theme!

While playing around with OpenCart 3.0.0.0 we were trying to create a new OpenCart 3.0 theme and for that, we copy the default theme and named “Webocreation” and was doing the following setting but got an error: “Warning: You do not have permission to modify the default store theme!”

So make the following changes to solve the problem:

The above error says we don’t have permission to modify so we tried to give permission as follows:

  • Admin >> System >> Users >> User Groups >> Edit the Administrator >> clicked “Select All” for both access permission and modify permission, then clicked save.

With the above permission, we should be able to get access but still got the same errors so we checked the code and found some glitch.

We checked admin\controller\extension\theme\default.php in OpenCart 3.0 and found following permission check at validate() method.

if (!$this->user->hasPermission('modify', 'extension/theme/theme_default')) {
    $this->error['warning'] = $this->language->get('error_permission');
}

But when we check at the User group permission it is extension/theme/default

extension theme default

So above code need to change to the following:

if (!$this->user->hasPermission('modify', 'extension/theme/default')) {
    $this->error['warning'] = $this->language->get('error_permission');
}

With this change, we are able to save, but still, we are not able to retrieve the save theme setting so we checked the code again and found the following:

if (isset($this->request->get['store_id']) && ($this->request->server['REQUEST_METHOD'] != 'POST')) {
    $setting_info = $this->model_setting_setting->getSetting('default', $this->request->get['store_id']);
}

So we changed it to following

if (isset($this->request->get['store_id']) && ($this->request->server['REQUEST_METHOD'] != 'POST')) {
    $setting_info = $this->model_setting_setting->getSetting('theme_default', $this->request->get['store_id']);
}

Then, it all starts to work. If you are also getting such an error, we hope it will help you to solve the problem. Enjoy and let us know if you are getting any kind of errors.

Rupak Nepali
Written byRupak Nepali

Rupak Nepali is a web developer, manage Webocreation website and the author of six books:
Getting Started with OpenCart Module Development (Packt, 2013),
OpenCart Theme and Module Development (Packt, 2015),
OpenCart 4: Dev Guide for Themes & Extensions (2024),
OpenCart 4: User Manual (2025),
Cloudflare for the Enterprise Website (2026) and
The Technical Web Guide for Marketers (2026).
Rupak has built OpenCart stores and extensions since 2010, has published more than 600 tutorials on Webocreation, and shares free OpenCart extensions on GitHub.
Find Rupak on
GitHub | Amazon | LinkedIn | X | YouTube.

10 comments

  1. Thanks for the Fix i really appreciate your effort but you’ve gone little far you don’t need the code where you’re changing the getsetting module it’s not needed the code will work fine with the permission code but if you edit the getsetting code it’ll not show the changes in the panel but it’ll change them please consider to edit your answer thanks

  2. Thanks for the Fix i really appreciate your effort but you’ve gone little far you don’t need the code where you’re changing the getsetting module it’s not needed the code will work fine with the permission code but if you edit the getsetting code it’ll not show the changes in the panel but it’ll change them please consider to edit your answer thanks

Leave a Reply

Your email address will not be published. Required fields are marked *