Showing results for 
Search instead for 
Did you mean: 

[PHP] add configurable product with simple (not showing)

[PHP] add configurable product with simple (not showing)



I made a php script to import 4000+ configurable products with 2+ simple associated, total 15000 (config + simple).


So, first I create array with ids of simple products and then I create configurable product. Every thing is filled. Image,price,... But configurable product does not appear on search or catalog.


I figured out, if I add simple product added to configurable product, then it appear on search and catalog.








----- here is not appear, so i do this ----


----- now appear on search ----


simple script:

config script:


All works fine, but is stupid.


Magento ver.


Thank you.


Re: [PHP] add configurable product with simple (not showing)

That sounds about right. Your configurable products need to be not only associated to simple products, but they need to have specific attributes labeled as super attributes (attributes that are configurable, such as size/color/etc.). And your simple products need to specify a value for each of these attributes as you've noticed. This is just the way it has to be. You might want to look into advanced product import and also possibly a custom profile that lets you specify these product links (super attributes for config products, related products, associated product skus, etc.).