Products and Categories at the Same Level

Restrictions on category contents

A basic rule of product structure in Zen Cart is: Products must be placed inside categories; products and categories cannot coexist at the same level.

Nevertheless, sometimes this can happen: direct database updates, bugs in plugins, and other situations can lead to such a scenario.

It’s easy to see when this has happened; go into Admin > Catalog > Categories/Products, and look at your categories. If you see the Action buttons out of alignment, you’ll know your category has both categories and products. You will also see the count at the bottom left hand side of the page show both products and categories.

Products and Categories same level

To fix this situation, use the purple “M” (move) button as needed. You may have to put a product in a category temporarily - as you can see, there is currently no “New Category” button on this page, because there’s a product in this category. Moving the product out will fix this issue.

Only Categories at a level

If you have this problem in a number of places in your database, you might want to consider using the Audit Plugin to track them all down and get them fixed.

Still have questions? Use the Search box in the upper right, or try the full list of FAQs. If you can't find it there, head over to the Zen Cart support forum and ask there in the appropriate subforum. In your post, please include your Zen Cart and PHP versions, and a link to your site.

Is there an error or omission on this page? Please post to General Questions on the support forum. Or, if you'd like to open a pull request, just review the guidelines and get started. You can even PR right here.
Last modified June 25, 2022 by Scott C Wilson (f991415).