I created attribute size in backend .I want to give the option to customer choose options from attribute value from product page .can any one tell how I call mydrop down attribute in product page.
2 Answers
- You can go through creating custom options. Check once https://www.magestore.com/magento-2-tutorial/how-to-add-custom-options-in-magento-2/ Or
- You can create configurable products. https://www.mageplaza.com/kb/how-to-configure-product-custom-options-in-magento-2.html
Then you can reach your requirements.
-
-
-
1Then go through custom options. do reindex and flush the cache. Then it will be displayed Commented Nov 19, 2018 at 8:33
You need to create select attribute for create option value product attribute.
You need to create simple module for this and inside module you need to create InstallData.php file.
Create PHP file inside Model and assign that file to product attribute in InstallData.php
file.
You can refer below module, For your requirement, Create Custom Option Product attribute in Magento 2