Setting default category for page

Last updated

By default Ecwid store shows a list of root categories on the page. You can change this behavior and display a particular product category, when customers open the storefront for the first time. This is useful if you only have one category or want to display a specific set of items (e.g. "Featured Products") to new visitors.

In Ecwid plugins for WordPress, Joomla, Wix and Facebook there is a special option: "Default Category" where you can select which category page will open. Check the guide on how to use this option in each plugin below.

  1. Facebook
  2. WordPress
  3. Wix
  4. Joomla
  5. Embed code

Facebook

1. Open Ecwid Facebook app settings page and click Settings.
2. Find the "Category opened by default" option and select the category page that will be displayed when the store loads.
image7.png

3. Click "Save" to apply the changes. 

WordPress

1. In WordPress Dashboard navigate to "Pages". Find your online store page and click "Edit".

image8.png

2. Click the "Edit store" button above the text editor area. The menu with store appearance settings will open.

image6.png

3. Switch to the "Appearance" tab and find the "Category shown by default" drop-down. Here you can select the category page that will be displayed when the store page loads.

image4.png

4. Click "Update" to save the changes and publish the page.

Wix

1. In the Wix website editor open the page where your Ecwid online store is added.
2. Click on the store area and click "Settings".

image1.png

3. Switch to the "Design" tab and scroll down to find the "Default Category" option.

image3.png

4. Choose which category page you want to show and click "Save" for the changes to be applied.

Joomla

1. In Joomla Control Panel navigate to Components > Ecwid > Advanced settings.

image2.png

2. In the "Category shown by default" drop-down select the category that you want to display.

image9.png

3. Click "Save" to apply the changes.

In case Ecwid is installed to several pages of your Joomla website, you can select different default category for each page, where the store is added. This is useful if you want to build a custom navigation in your Ecwid store.

1. Navigate to "Menus" and open the page where Ecwid is installed in edit mode.
2. Switch to the "Basic Ecwid settings" tab and find the "Category shown by default" drop-down. Here you can choose which Ecwid category will open on this page.
image5.png

3. Click "Save" to apply the changes and repeat the steps for each page where Ecwid is installed. 

Embed code

In case your Ecwid store is installed on your website by means of embed code, you can set the default category for the page by adding a special parameter into the code:

defaultCategoryId=%categoryId%

This is a sample embed code that opens a list of root categories (without default category ID parameter):

<div> <script type='text/javascript' src='https://app.ecwid.com/script.js?1003'></script> <script type='text/javascript'> xProductBrowser("categoriesPerRow=3","views=grid(3,3) list(10) table(20)","categoryView=grid","searchView=list","style="); </script> </div>

This is the same code that opens a particular category page (with default category ID parameter):

<div> <script type='text/javascript' src='https://app.ecwid.com/script.js?1003'></script> 
<script type='text/javascript'> xProductBrowser("categoriesPerRow=3","views=grid(3,3) list(10) table(20)",
"categoryView=grid","searchView=list","style=","defaultCategoryId=3003");</script>
</div>

The category is defined by its ID. In our example it’s 3003. The category ID is included into the category page URL. If you can’t find it, check the guide How to get the ID of your product or category.

Was this article helpful?
7 out of 13 found this helpful
Questions?
Get help
  • Forums

    Join the Ecwid community. Discuss support topics and store ideas with other Ecwid users.

  • Contact us

    Still have questions about Ecwid? Let us know! We will be glad to help you with your Ecwid store.

  • Status Monitor

    Get real time status updates on Ecwid services here, 24/7