free
web stats

Fill the form & Get Installation Support

We don't monkey around your business.

GET IN TOUCH WITH US NOW





captcha

Magento 2.3.x Attributes options not created correctly programmatically

If you want to create product attribute options programatically, but not by admin then this blog post is right the solution for you.

You need to add below code in controller.

Codes for 2.2.x & 2.3.x will be different.

Code for Magento 2.2.X :

Code for Magento 2.3.X

I hope adding the above codes in their respective versions of your Magento store will help you to create product attribute options. Let us know by comment if it worked for you or not?