we have 5000 products in site

we have 5 attribute-set , each attribute have 1000 products each.

for products of only one attribute set, under description tab, we have to add this text " color may vary as shown in above image"

how we can achieve this for only one attribute-set products.

we don't want this text for other attribute-set products


you can achieve this simply adding in product detail page..

    <?php $attributeSetModel = Mage::getModel("eav/entity_attribute_set");
echo $attributeSetName  = $attributeSetModel->getAttributeSetName();
if($attributeSetName=='you attibute name'){ echo $this->__('color may vary as shown in above image'); } ?>
  • Fatal error: Call to a member function getAttributeSetId() on a non-object in $attributeSetModel->load($product->getAttributeSetId()); – Baby in Magento Jan 27 '16 at 10:05
  • use $_product->getAttributeSetId() – Qaisar Satti Jan 27 '16 at 10:06
  • Parse error: syntax error, unexpected ';' in smae line , i am using this : $attributeSetModel->load($_product->getAttributeSetId(); – Baby in Magento Jan 27 '16 at 10:09
  • where you are placing this code? – Qaisar Satti Jan 27 '16 at 10:11
  • in the end of the view.phtml file – Baby in Magento Jan 27 '16 at 10:12

If I understand right your question one of the solution is that you can do this with the following steps using import/export :
- export all your product from the wanted attribute set
- modify the exported file with your new attribute value
- import the file

  • but if i update like this, the description will lost for all 1000 products. we added different description for different products. – Baby in Magento Jan 27 '16 at 9:54
  • OK I misunderstand your quesiton, please see my edit – Matthéo Geoffray Jan 27 '16 at 9:58
  • No problem, we will check it. – Baby in Magento Jan 27 '16 at 10:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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