More than 1000+ satisfied clients and counting, since 2010

Blog

Create Custom Admin Page in OpenCart Stores

Create Custom Admin Page in OpenCartOpenCart is a free open source content management system. It can be used to develop and maintain an eCommerce website for online stores. Its unique features let store managers to create a uniquely designed shopping cart for their business.

One such customization which you can implement on your website is the provision to create custom admin page in OpenCart. Using it you can change the look and feel of the backend of the store as well. This blog post will help you create custom admin page in OpenCart run websites.

Steps to Create Custom Admin Page in OpenCart

  • Create a new file in admin/controller/custom/helloworld.php
  • Inside helloworld.php, place the following code:
<?php
class ControllerCustomHelloWorld extends Controller{
public function index(){
$this->load->model('catalog/information');
$this->template = 'custom/hello.tpl';
if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . 'custom/hello.tpl')) {
$this->template = $this->config->get('config_template') . 'custom/hello.tpl';
} else {
$this->template = 'custom/hello.tpl';  }
$this->children = array(
'common/header',
'common/footer' );
$this->response->setOutput($this->render());
}  }
?>
  • Create a new file in admin/ view/template/custom/hello.tpl
  • Place the following code inside hello.tpl:
<?php echo $header; ?>
<div id="content">
<h1>HelloWorld</h1>
<?php
echo 'I can also run PHP too!';
?>
</div>
<?php echo $footer; ?>
  • Enable the plugin to avoid permission denied errors

Opencart > Admin > Users > User Groups > Admin > Edit

  • Select and Enable the access permission

View the Custom OpenCart Admin Page

www.yoursite.com/opencart/admin/index.php?route=custom/helloworld

If you are unable to create custom admin page in OpenCart, then Request a Quotewith us. Our team of OpenCart developers will provide expertise solutions and help you create custom admin page in OpenCart.

Apart from offering support services, we also deal with PSD to OpenCartconversion and HTML to OpenCart template conversion services as well. If you want to develop a fully functional OpenCart online store for your business then contact us for quality and affordable services.

Written by

The author didnt add any Information to his profile yet