OpenCart config url,dir path problem and htaccess issue

Opencart is another easy, robust and handy e-commerce CMS. For beginner, there are some common problem related to URL, Directory path and .htaccess issues.

Following issues need to keep in mind during installation, moving to another server or installation on windows:

  • Use trailing slash after the url like define(‘HTTP_SERVER’, ‘localhost/myproject/’) otherwise it may not load all css, images and js files.
  • For windows, use path like define(‘DIR_APPLICATION’, ‘F:\wamp\www\myproject/catalog/’); as well as for other settings. It may be ok in normal way like define(‘DIR_APPLICATION’, ‘F:/wamp/www/myproject/admin/’);
  • For htaccess, if your store/project is in your document root which is generally public_html on cpanel servers that is ok for for default RewriteBase, but if it’s in a subfolder you will need to edit the file and change the ‘RewriteBase /’ to ‘RewriteBase /subfoldername/’

That’s all for some common issue. Have fun with open source opencart 🙂

Advertisements