Reputation: 135
I am very new to magento and I want to add a custom option to the Custom Options as described in the title. I think that I am already in the right file wich is : app->design->adminhtml->default->default->template->catalog->product->edit->options->option.phtml So now is my question, how do I add custom options in there so I can select some of my own code. For further declaration i'll add a screen shot that might help explain what I mean to do. http://prntscr.com/38nk5b I have to insert it like this because I don't have enough reputation yet to post a picture. Apoligy for that.
Upvotes: 2
Views: 687
Reputation: 1720
You can add custom options from Magento admin.
Goto Admin->catalog->Manage Products
click on any products. In the left navigation at the bottom there is custom options
tab.
Add custom options from there for each product.
OR
$option = Mage::getModel('catalog/product_option');
$option->setProduct($product);
$values = array(
//data here
);
$product->setHasOptions(1); //Hope you can get the $product
$option->addOption($values);
$option->saveOptions();
$product->addOption($option);
check this http://pravams.com/2011/05/25/magento-create-custom-options-dynamically/
Upvotes: 0