Posted over 5 years ago. Visible to the public. Linked content.

Creating a New Attribute Set Programatically

$entityTypeId = Mage::getModel('catalog/product') ->getResource() ->getEntityType() ->getId(); $attributeSet = Mage::getModel('eav/entity_attribute_set') ->setEntityTypeId($entityTypeId) ->setAttributeSetName('test_set'); $attributeSet->validate(); $attributeSet->save(); $attributeSet->initFromSkeleton($skeletonID)->save();

You need to save before you do initFromSekeleton().

Owner of this card:

Mike Whitby
Last edit:
over 5 years ago
Posted by Mike Whitby to Magento
This website uses cookies to improve usability and analyze traffic.
Accept or learn more