If you need to configure OpenCart to work properly with a new domain name, you will need to modify the two configure.php files in the main OpenCart Folder / and the OpenCart Folder/admin/ folders to each reflect the new domain.

Here below are the lines of the OpenCart Folder/configure.php file that will need to be changed:

// HTTP
define(‘HTTP_SERVER’, ‘http://yournewdomainname.com/’);
define(‘HTTP_IMAGE’, ‘http://yournewdomainname.com/image/’);
define(‘HTTP_ADMIN’, ‘http://yournewdomainname.com/admin/’);

// HTTPS
define(‘HTTPS_SERVER’, ‘http://yournewdomainname.com/’);
define(‘HTTPS_IMAGE’, ‘http://yournewdomainname.com/image/’);

// DIR
define(‘DIR_APPLICATION’, ‘/home/sites/yournewdomainname.com/public_html/catalog/’);
define(‘DIR_SYSTEM’, ‘/home/sites/yournewdomainname.com/public_html/system/’);
define(‘DIR_DATABASE’, ‘/home/sites/yournewdomainname.com/public_html/system/database/’);
define(‘DIR_LANGUAGE’, ‘/home/sites/yournewdomainname.com/public_html/catalog/language/’);
define(‘DIR_TEMPLATE’, ‘/home/sites/yournewdomainname.com/public_html/catalog/view/theme/’);
define(‘DIR_CONFIG’, ‘/home/sites/yournewdomainname.com/public_html/system/config/’);
define(‘DIR_IMAGE’, ‘/home/sites/yournewdomainname.com/public_html/image/’);
define(‘DIR_CACHE’, ‘/home/sites/yournewdomainname.com/public_html/system/cache/’);
define(‘DIR_DOWNLOAD’, ‘/home/sites/yournewdomainname.com/public_html/download/’);
define(‘DIR_LOGS’, ‘/home/sites/yournewdomainname.com/public_html/system/logs/’);

 

You will also need to make the same modifications in your OpenCart Folder/admin/configure.php file:

 

// HTTP
define(‘HTTP_SERVER’, ‘http://yournewdomainname.com/admin/’);
define(‘HTTP_CATALOG’, ‘http://yournewdomainname.com/’);
define(‘HTTP_IMAGE’, ‘http://yournewdomainname.com/image/’);

// HTTPS
define(‘HTTPS_SERVER’, ‘http://yournewdomainname.com/admin/’);
define(‘HTTPS_IMAGE’, ‘http://yournewdomainname.com/image/’);

// DIR
define(‘DIR_APPLICATION’, ‘/home/sites/yournewdomainname.com/public_html/admin/’);
define(‘DIR_SYSTEM’, ‘/home/sites/yournewdomainname.com/public_html/system/’);
define(‘DIR_DATABASE’, ‘/home/sites/yournewdomainname.com/public_html/system/database/’);
define(‘DIR_LANGUAGE’, ‘/home/sites/yournewdomainname.com/public_html/admin/language/’);
define(‘DIR_TEMPLATE’, ‘/home/sites/yournewdomainname.com/public_html/admin/view/template/’);
define(‘DIR_CONFIG’, ‘/home/sites/yournewdomainname.com/public_html/system/config/’);
define(‘DIR_IMAGE’, ‘/home/sites/yournewdomainname.com/public_html/image/’);
define(‘DIR_CACHE’, ‘/home/sites/yournewdomainname.com/public_html/system/cache/’);
define(‘DIR_DOWNLOAD’, ‘/home/sites/yournewdomainname.com/public_html/download/’);
define(‘DIR_LOGS’, ‘/home/sites/yournewdomainname.com/public_html/system/logs/’);
define(‘DIR_CATALOG’, ‘/home/sites/yournewdomainname.com/public_html/catalog/’);

 

OpenCart is now available as an easy 1 click install on our, Starter, Home, Business, Business Pro, web hosting plans.

Shares
Share This