2011-08-30 37 views

回答

1

我解決了這個問題:

require_once 'app/Mage.php'; 
Mage::app(''); 
$attribute = Mage::getModel('eav/config') 
      ->getAttribute('catalog_product', '955'); 
    foreach ($attribute->getSource()->getAllOptions(true) as $option){ 

    //here comes the code sample (see link before) 
        . 
        . 
        . 
    $product->setMyCustomAttribute($option['value']); 
} 
+0

請註明自己的答案被接受,它是允許的,甚至是計算器的規則建議。 – Zyava

相關問題