We have a magento store and we have over 1000 products listed. We want to assign random related products, but they should be within the category. For example, if a product is listed under Men >> T-shirts category, related products should also be from T-shirt category only. Is there a way to do this using code instead of manually assigning related products?

1 Answer 1


In the latest version of Magento Enterprise you can use the rule based product assignments to category. You can go to visual Merchandiser and set the rule you want. No code is needed. You will get an option to adjust then assigned products.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.