Four Easy Steps to Set Up Multi-Store in OpenCart
OpenCart is one of the most popular eCommerce platforms available on the market today. In this article, we will walk through the simple steps involved in setting up the multi-store feature using a single OpenCart installation.
Join the DZone community and get the full member experience.Join For Free
OpenCart is one of the most popular eCommerce platforms available on the market today. It is widely preferred by small and medium sized organizations who are looking for a secure, stable, and robust eCommerce platform with the necessary features to run an online store. Like some other frameworks, OpenCart lets businesses offer multiple stores in a single installation.
In this article, we will walk readers through a simple workflow of a multi-store setup using a single OpenCart installation. We will also explore what exactly a multi-store setup is and its benefits, while implementing multiple websites.
What Are Multi-Stores?
Let us assume you are an entrepreneur who has been successful in launching a profitable online store that sells products using OpenCart. As a decision maker, you hope to provide a larger variety of products to your customers. However, you do not want to clutter everything in the same store. So, what do you do?
You may decide to set up distinct sub-domains for every major product category. For instance, "books.yoursite.com" would display all the books you want to sell online. While "shoes.yoursite.com" represents your online shoe store! This is especially useful since you can maintain a unique look and feel for specific sub-domains on the basis of the products they stand for.
Let's assume you aren't familiar with the multi-store setup functionality of OpenCart. In such a scenario, you may need to copy and replicate OpenCart installation for each sub-domain and repeat this process for the database too. Copy and pasting may sound like an easy job at first, but in the long run it gets messier when you have to maintain all the sub-domain sites. Imagine what would happen if you werere to use third party extensions for your stores? Store management would become a nightmare!
This is where a multi-store management feature can act as a savior. It lets you set up a number of stores using just one installation of OpenCart.
Let's look at the simplest way to set up multi-store and the corresponding workflow involved to do so, in detail.
1) Set Up a New Sub-domain: Prior to setting up a new store in the OpenCart back-end, make sure that you already have a sub-domain or a domain that points to the default OpenCart installation. This can be done through the control panel of your hosting provider. For the rest of the workflow walk through, we'll consider "www.yourexamplestore.com" as the primary default OpenCart installation and "store1.yourexamplestore.com" as our brand new store.
2) Create a New Store From the Back-End: First, go to the back-end of OpenCart and follow these steps:
Move to System > Settings. Here you can see all the available stores in OpenCart. In a majority of cases, there will just be a single entry for your default and only store, and it will list all of the stores available in OpenCart. To add a new store, click on the Insert button.
The store creation interface has a number of tabs like: General (set up the store URL here), Store (choose a theme or set up default cart layout here), Local (set language, country, and select the currency your user should be prompted with during checkout), Image (upload a store icon or logo), etc.
Once you include all of the details required, click on the Save button to create a new store.
3) OpenCart Multi-Store Management: After setting up a shiny new store in the OpenCart back-end, there are a few things you can do for setting up different options/menus like:
- Front-end Theme
- Page Layouts
Let's take a shot at including store-specific categories.
Go to the back-end: Find Catalog > Categories to view the list of categories. Click on Insert to add a new category.
Include a New Category – Store Selection Tab: Just below the Data tab, you will notice a field called 'Stores'. This displays all the stores in your OpenCart installation. The new category will only be shown below the selected stores and not all the ones available.
In this manner, you will be able to add as many categories as you like for your store. A similar process can be followed for other entities such as "Products", "Manufacturers", etc.
4) Front-End Considerations: eCommerce platforms usually allow you to have different themes for online stores. During OpenCart web development, you can assign a different theme for stores. It is a good practice, therefore, to design a distinct look and feel for each of your stores as they are all separate sites. This will also help in store management, as customer/order accounts are created from the front-end and associated with the corresponding store from where they were created.
In short, with the steps outlined above, you should be able to leverage all of the OpenCart features and move your scattered web stores to a uniform, single, multi-store-based OpenCart site.
Opinions expressed by DZone contributors are their own.