How to get product attribute color text from quote item?Get Attribute of products of the products in cart at onestepcheckoutCustom value into Quote Item table?Used product attributes in order itemAdding a product to cart with different custom attributes inherits attributes of first itemGetting an item from quote objectRemove item from Quote item - Magento1.9Adding custom attribute to quote itemAdd a quote instance to cart: Magento 2get Quote Item ID from event checkout_cart_product_add_after not workingMagento2: How to get quote item through item id?getItemById($itemId) for Magento Quote Model not working as expected in Magento 2
Is there a linguistic basses for how to translate John 8:43, or are translations basing their translation on context alone?
Is it OK to look at the list of played moves during the game to determine the status of the 50 move rule?
What to call a small, open stone or cement reservoir that supplies fresh water from a spring or other natural source?
Make the `diff` command look only for differences from a specified range of lines
Can someone get a spouse off a deed that never lived together and was incarcerated?
Is there a word for pant sleeves?
size of pointers and architecture
Variable does not Exist: CaseTrigger
Is the default 512 byte physical sector size appropriate for SSD disks under Linux?
Passport queue length in UK in relation to arrival method
Why is a weak base more able to deprotonate a strong acid than a weak acid?
Split into three!
Why is Ni[(PPh₃)₂Cl₂] tetrahedral?
Why does the -OH group in β-naphthol direct the incoming diazonium salt towards the ortho position?
Which are the advantages/disadvantages of includestandalone?
A nasty indefinite integral
How do you earn the reader's trust?
Singular Integration
Is being an extrovert a necessary condition to be a manager?
Why the work done is positive when bringing 2 opposite charges together?
How to safely discharge oneself
Is a world with one country feeding everyone possible?
Are there historical examples of audiences drawn to a work that was "so bad it's good"?
What does it mean for something to be strictly less than epsilon for an arbitrary epsilon?
How to get product attribute color text from quote item?
Get Attribute of products of the products in cart at onestepcheckoutCustom value into Quote Item table?Used product attributes in order itemAdding a product to cart with different custom attributes inherits attributes of first itemGetting an item from quote objectRemove item from Quote item - Magento1.9Adding custom attribute to quote itemAdd a quote instance to cart: Magento 2get Quote Item ID from event checkout_cart_product_add_after not workingMagento2: How to get quote item through item id?getItemById($itemId) for Magento Quote Model not working as expected in Magento 2
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I want track quote items color and brand in our checkout process. Regarding this answer I should do this in config.xml:
<global>
<sales>
<quote>
<item>
<product_attributes>
<color />
</product_attributes>
</item>
</quote>
</sales>
</global>
And this in my checkout process:
<?php
foreach($cartItems as $_quoteItem)
echo $_quoteItem->getProduct()->getAttributeText('color');
?>
But this is not working - result is nothing.
magento-1.9 product-attribute configuration quoteitem
add a comment |
I want track quote items color and brand in our checkout process. Regarding this answer I should do this in config.xml:
<global>
<sales>
<quote>
<item>
<product_attributes>
<color />
</product_attributes>
</item>
</quote>
</sales>
</global>
And this in my checkout process:
<?php
foreach($cartItems as $_quoteItem)
echo $_quoteItem->getProduct()->getAttributeText('color');
?>
But this is not working - result is nothing.
magento-1.9 product-attribute configuration quoteitem
add a comment |
I want track quote items color and brand in our checkout process. Regarding this answer I should do this in config.xml:
<global>
<sales>
<quote>
<item>
<product_attributes>
<color />
</product_attributes>
</item>
</quote>
</sales>
</global>
And this in my checkout process:
<?php
foreach($cartItems as $_quoteItem)
echo $_quoteItem->getProduct()->getAttributeText('color');
?>
But this is not working - result is nothing.
magento-1.9 product-attribute configuration quoteitem
I want track quote items color and brand in our checkout process. Regarding this answer I should do this in config.xml:
<global>
<sales>
<quote>
<item>
<product_attributes>
<color />
</product_attributes>
</item>
</quote>
</sales>
</global>
And this in my checkout process:
<?php
foreach($cartItems as $_quoteItem)
echo $_quoteItem->getProduct()->getAttributeText('color');
?>
But this is not working - result is nothing.
magento-1.9 product-attribute configuration quoteitem
magento-1.9 product-attribute configuration quoteitem
edited Apr 13 '17 at 12:55
Community♦
1
1
asked May 10 '16 at 9:47
JurikJurik
1539
1539
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
Your config.xml file is correct, however, retrieving the attribute value for configurable or simple products differs. If you have configurable product in cart, but the attributes are set for its simple products, consider this solution:
foreach ($cartItems as $_quoteItem)
$simpleProductOption = $_quoteItem->getOptionByCode('simple_product');
$color = $simpleProductOption->getProduct()->getAttributeText('color');
Sorry, I do not have enough reputation to comment/ask whether you need this done for configurable products or simple products, or any other products, but I hope this helps you!
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "479"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f114693%2fhow-to-get-product-attribute-color-text-from-quote-item%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Your config.xml file is correct, however, retrieving the attribute value for configurable or simple products differs. If you have configurable product in cart, but the attributes are set for its simple products, consider this solution:
foreach ($cartItems as $_quoteItem)
$simpleProductOption = $_quoteItem->getOptionByCode('simple_product');
$color = $simpleProductOption->getProduct()->getAttributeText('color');
Sorry, I do not have enough reputation to comment/ask whether you need this done for configurable products or simple products, or any other products, but I hope this helps you!
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
add a comment |
Your config.xml file is correct, however, retrieving the attribute value for configurable or simple products differs. If you have configurable product in cart, but the attributes are set for its simple products, consider this solution:
foreach ($cartItems as $_quoteItem)
$simpleProductOption = $_quoteItem->getOptionByCode('simple_product');
$color = $simpleProductOption->getProduct()->getAttributeText('color');
Sorry, I do not have enough reputation to comment/ask whether you need this done for configurable products or simple products, or any other products, but I hope this helps you!
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
add a comment |
Your config.xml file is correct, however, retrieving the attribute value for configurable or simple products differs. If you have configurable product in cart, but the attributes are set for its simple products, consider this solution:
foreach ($cartItems as $_quoteItem)
$simpleProductOption = $_quoteItem->getOptionByCode('simple_product');
$color = $simpleProductOption->getProduct()->getAttributeText('color');
Sorry, I do not have enough reputation to comment/ask whether you need this done for configurable products or simple products, or any other products, but I hope this helps you!
Your config.xml file is correct, however, retrieving the attribute value for configurable or simple products differs. If you have configurable product in cart, but the attributes are set for its simple products, consider this solution:
foreach ($cartItems as $_quoteItem)
$simpleProductOption = $_quoteItem->getOptionByCode('simple_product');
$color = $simpleProductOption->getProduct()->getAttributeText('color');
Sorry, I do not have enough reputation to comment/ask whether you need this done for configurable products or simple products, or any other products, but I hope this helps you!
answered May 10 '16 at 12:08
user43526
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
add a comment |
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
We are using both. The configurable products are the containers for our simple products. But I am really new to this stuff - could be that I mixed up something.
– Jurik
May 10 '16 at 12:18
add a comment |
Thanks for contributing an answer to Magento Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f114693%2fhow-to-get-product-attribute-color-text-from-quote-item%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown