Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [option]

The tag has no usage guidance.

0
votes
1answer
25 views

Add options to quote programmaticaly

I'm creating quote and order programmaticaly. I can't figure out why options product are not added to my order / quote. See : $superAttr = $item["super_attribute"]; if(!empty($superAttr)){ $...
1
vote
1answer
26 views

Get values of customizable option

Is there a way to get the SKU of the option of my product ? Can't make anything works Tried this : $customOptions = $objectManager->get('Magento\Catalog\Model\Product\Option')->...
1
vote
1answer
22 views

How to add custom attribute to select options?

Is it possible to add custom values to select options e.g. in configurable products? I need to add the sku of the option to the option, so that it will become <option id="354" price="10" sku="...
2
votes
1answer
18 views

Adding option to a product create error

I'm extending the \Magento\Catalog\Block\Product\View file in AddToCart.php. In my AddTocart, I've added this line : $stock = $this->isInStockCustom($sku); Now, I'm adding options to my ...
0
votes
0answers
21 views

Empty row in dropdown admin panel magento 2

I had empty row in drop down for attribute in adminpanel. Although there is no empy value while creating attribute.How to remove it.
5
votes
1answer
98 views

Magento 2 : Bundle product should goes Out of stock if default option is not in stock

Magento2 default behaviour if default option of bundle product is not in stock, system should check for second option and set that option as a default and bundle product should stay as in-stock. ...
0
votes
1answer
324 views

Magento2 how to remove “choose an option” in configurable products drop down

How to remove "choose an option" in configurable products drop down and in the drop-down menu have the first attribute value be the top choice please if anyone idea reply me I need this type of
0
votes
0answers
27 views

Magento 2 reset widget option

I'm working on a custom widget that allows adding multiple CMS blocks instead of one. It's working fine, however when the blocks have been selected they cannot be removed anymore (they can only be ...
2
votes
1answer
149 views

Get attibute label option for current store

I have a 'size' attribute with lot of option. For each option, I have translation for each my stores : I want to get the translation label for a product and for a given store. So : I load my ...
1
vote
3answers
754 views

Magento 2.2.3 - Remove price from select field on product page

I was trying to remove the price which Magento adds to the options in a Select field but can't seem to get rid of the price. From what I could find on the internet it should be edited on the following ...
1
vote
2answers
208 views

How to delete color attribute option by using label in Magento 2?

Can we delete product attribute options by using label? For example say attribute:color has options like green, red, yellow how to delete red from this? I used below code. $objectManager = \...
0
votes
1answer
560 views

How to add new Option to drop down attributes magento2?

How to add an new option to product dropdown attribute? If the option already exist it has to skip adding else add option with new value. I followed the below link How Magento2 add attribute option ...
0
votes
1answer
908 views

Magento 2 : Get Category Attribute Value By Option Id

How to get category attribute value by option id in magento 2. Thanks
2
votes
0answers
905 views

Update Options of a Select Element Dynamically using Knockout Js

I am looking for updating a custom Select Option at Checkout. <select name="city" id="city" data-bind=" options: availableCities, optionsText: 'name', optionsCaption: 'Select City', ...
0
votes
3answers
2k views

Magento 2 Can't add Attribute option upto 100 ? Is there any limit for the option?

I have an issue with the product options. There are 500 option for the attribute but can't add after 100 options. Can you please let me know about this issue? The Product Attribute is successfully ...
1
vote
1answer
162 views

Something is overriding my onchange script?

I made a script that selects an option from a dropdown. The dropdown has onchange trigger and it trigger correctly when i run the script as a snippet (in a sandbox environment), but when i active the ...
1
vote
1answer
347 views

Javascript ReferenceError: reloadPriceOfSingleProduct is not defined

I get following errors in console of my browser if I change options on a Product under magento 1.9.3.3 : Uncaught TypeError: Cannot read property 'success' of undefined at klass.initialize (prototype....
2
votes
2answers
235 views

Unable to access custom options section [closed]

Using mageworx advance product options extension i have created option templates and associated to the products and saved. in the magento 1.9.2.4 Now i came to product and clicked on 'custom options'...
3
votes
2answers
2k views

How can i remove the dropdown option in country in checkout page in magento? I need to put only one country

From the following files : /app/design/frontend/base/default/template/customer/form/reg‌​ister.phtml /app/design/frontend/base/default/template/customer/form/add‌​ress.phtml /app/design/...
2
votes
1answer
2k views

Magento2 : How to load quote item option by id?

In a module under Magento 1.9. I was loading quote item option using $_quoteOption = Mage::getModel('sales/quote_item_option')->load($Option_id); I would like to do the same thing under magento2 ...
3
votes
2answers
4k views

Magento 2 : Get Quote Item Selected Options

Programetically I want fetch, quote item options which is selected. I added product with options like, Color : Red Size : 6 Now I want to fetch that selected option programetically in another ...
0
votes
0answers
176 views

Magento : Grouped Product with Configurable Product Mandatory to Add to Cart

I have a few grouped products, with more than one configurable products (with different colors as simple product) associated as sub products. The problem is, because simple product (colors) in a ...
2
votes
1answer
392 views

Magento2 : Auto Select Options for Products with Multiple Options

I'm trying to get url with already selected options. If I have only one options, code is working fine adding #{attribute_id}={attribute_value} after url. https://nyhomedecor.com/cordless-dual-sided-...
1
vote
1answer
837 views

How to get selected option of the attribute for the product?

Struggling to get value of the selected option for product. Example:Product require assembly so created attribute dropdown Below few methods I've tried echo $data = $_product->getAssembly(); echo ...
0
votes
1answer
425 views

Magento add another custom dropdown field in bundle items of bundle product

How to add new dropdown field, next to the position field of bundle item like shown in the below screenshot.
0
votes
1answer
99 views

How to set the option type area in Magento 2?

In Magento 1 ($optionType == Mage_Catalog_Model_Product_Option::OPTION_TYPE_AREA): But, in Magento 2, I have to pass responsible class object type in constructor. How I change this in Magento 2?
1
vote
0answers
45 views

Get Option Description by Option ID (outside the product)

I got Option ID from single attribut in category page by: $request = $this->getRequest()->getParams(); Of course i parse it and i receive attribute name and attribute option ID. I want ...
1
vote
1answer
769 views

How to add a selection for an option in bundle items in Magento

I have already created Bundle product in magento 1.9.2.2. All the bundle items are of "Radio Buttons" input type having few options already defined to them. This I have created using admin-panel. ...
0
votes
1answer
189 views

my radio button can't save to my database

i have table 'a_installment' and the column is 'id' and 'nama', i try save to 'a_installment' using radio button with this code etc/config.xml <?xml version="1.0"?> <config> <...
2
votes
0answers
371 views

How can I get Visual Swatch option imange in magento 2 product view page

I have attribute option Id but I can't get the image of swatch. Is there any way of getting image.
0
votes
1answer
194 views

Magento Exception:Wrong product type to extract configurable options

I have a custom module for viewing products in cart at the My account Dashboard. It's working fine, but some times it throws exceptional error at the getItemOptions() function. Customer/Block/Cart....
0
votes
1answer
757 views

Magento Product Custom option value setPrice not working programmatically

I just don't get it. I have installed Magento 1.9.2.2 CE in my site. But when I run following code as custom script from root directory, it doesn't set product custom option value price to my desired ...
2
votes
1answer
1k views

Bundle Products - how to use 2 different renderers for bundled product options? (to show in tab)

I need two renderers for Bundle Product Select Style Options, to show the same thing differently in two places. Context: At the moment all my bundle products are fixed (wine cases). I have decided ...
1
vote
1answer
93 views

Multiple Price Options -

I am trying to have multiple price options for books, for example Book A - hardcover will be $20 and softcover will be $16.00 But I want it to display the price as "$16-$20" or say "Price Varies" ...
2
votes
0answers
37 views

Shipping options

I am looking to create different shipping options for HI, AK as compared to the rest of the States. For HI, AK I want to charge $15 a shipment and ship USPS. For the rest of the states I want to ...
1
vote
2answers
1k views

Magento Translation of option labels and values [closed]

I have 6 store views for different languages. My problem is, $_option['label'] and the $_option['value'] which are using in product-view page, cart page, cart-sidebar, onepage-chekcout is always ...
1
vote
0answers
34 views

Product Attribute option values has 100's of empty option values, using Magento 1.9.1 [duplicate]

I am using Magento 1.9.1 and facing a weird issue for long time, our attribute option values has 100's of empty option values and the new issue is in some attributes which have more values it is not ...
1
vote
1answer
712 views

How to assign Custom select box option value in custom form?

Here i working custom form with custom select box in magento.I need to assign Custom select box with option value attributes and option values . Here i working custom form sample code: $fabrics =...
2
votes
2answers
2k views

Specific price per quantity

I'm trying to set a product with different prices depending on quantity "chosen from drop-down" But I have no idea how to create this. basically I have a product which comes in this quantities: 20, ...
1
vote
0answers
535 views

How to change “Use In Search Results Layered Navigation” option of attributes?

So I created a custom attribute called 'weight'. When I search for a product in the Frontend, it shows 'Weight' in the Search Result options sidebar because I left "Use In Search Results Layered ...
0
votes
1answer
103 views

Option ID is shown instead of option value [closed]

As a German Shop we need to echo delivery time into the top of the productpage and the product grid. Normaly it does what it should, but in our latest installation it shows the option id instead of ...
7
votes
3answers
11k views

Add product to cart with custom option using PHP

I am trying to add a product to the cart programmatically with some custom options. The item gets added to the cart correctly but none of the options ever get added. My code is: require_once '../../...
0
votes
2answers
2k views

Custom event on product option change

In my magento store my products have several custom options which alter the price of the product. I also need to add in a custom function which shows or hides particular content when this event ...
0
votes
3answers
112 views

Narrowing shipping method to only 1 option?

I have a product that weighs 30 lbs. However, when a customer orders multiples of this product--say, 10 of them--the total weight should be 300 lbs. I have an extension for FedEx Freight that is ...
2
votes
2answers
856 views

Get ID of newly created product attribute option

In my magento store I am creating a new product attribute option as so: $new_name = 'my-new-option'; $_attribute = Mage::getModel('eav/entity_attribute')->loadByCode('catalog_product', 'my-...
1
vote
1answer
729 views

Where is Option Id of Newly Added Option For Bundle Product?

So I have a module, which I am using to set a custom field in bundle options. I have implimented my module successfully. However I came to a situation to which I can't move on without get an answer ...
2
votes
1answer
2k views

Set default option as “No” for custom select attribute

I have used below code to generate a custom select attribute. $installer->addAttribute('catalog_product', "best_seller_flag", array( 'type' => 'int', 'group' => 'Flags', ...
1
vote
1answer
605 views

How to search against product options

I have products which have options that include their associated part#'s and model#'s in text as shown here http://greengaskets.com/index.php/manufacturer/bally-gasket-profile-10130.html However I am ...
5
votes
2answers
4k views

Remove and recreate custom option programatically on product before save event

I m creating custom option programatically using observer with catalog_product_save_before event.Custom option created successfully on product save.but the problem is whenever product save second time ...
6
votes
2answers
3k views

How does magento create bundle option selections?

I've been looking at programmatically creating bundle products, and got stuck on adding a selection to the options. The problem is that when you create a new selection (Mage_Bundle_Model_Selection) ...