I've hit a wall with this one. I using Stash and template partials to set my page. Currently I am NOT caching anything.

I have products that have product options associated with them and I have tried several approaches to try at get this to work. The bottom line is, that if I have the Carthtrob {exp:cartthrob:item_options entry_id="{entry_id}"} tag on the page, the product fails to add to the cart.

I have tried to use this as a standalone and use Stash to pass an entry ID, I've also tried to set it as a stash item {stash:product_opt}code-here{/stash:product_opt}.

Stash is parsing the tags and outputting them. I am presuming it is a delightful parse order issue! Another thing I have tried is to embed it and also use it as a snippet. No cigar sadly.

Has anyone come across this?

{exp:stash:set_list name="{segment_1}-Product" parse_tags="yes" scope="site" save="no" replace="no" refresh="1440"} {exp:channel:entries channel="products" status="open" url_title="{last_segment}"}



{exp:cartthrob:item_options entry_id="{entry_id}" parse="inward"}
{if dynamic}
    <dd class="productOption">{input}</dd>

{if configuration} config{/if}
{if options_exist}
    {if configuration_label}{if:else} <dt>{option_label}</dt>{/if}
    <dd class="productOption">
        <option {selected} value="{option_value}">
            {option_name}{if option_price_numeric > 0} +{option_price}{/if}

{/exp:channel:entries} {/exp:stash:set_list}

Many thanks

  • Have you tried adding parse_depth="2" to your set_list tag? You have some nested module tag pairs there. May 7, 2013 at 16:34
  • Thanks Rob. Yea, I have tried that. If the tag is parsing before Stash works with it, can you think of any other reason why this wouldn't work?
    – T2theC
    May 7, 2013 at 19:12

1 Answer 1


I've completed something similar but we captured all entries to a to a series of big stash lists then used get_list name="{segment_1}-Product" match="#{last_segment}#" against="urltitle"} to pull in the relevant item or series of items.

This is the base theory we used, you'll have to experiment to get it to work in your scenario...

//Just capture the elements you require, leave styling to later…
//Set depth to 2, we're parsing exp:channel + also getting nested info from item:options
{exp:stash:set_list name="{segment_1}-Product" parse_tags="yes" scope="site" parse_depth="2"save="no" replace="no" refresh="1440"} {exp:channel:entries channel="products" status="open" url_title="{last_segment}"}
    //Capture the options as a nested list
    {exp:stash:set_list:nested name="product_options{entry_id}" parse_tags="yes" scope="site"}
        {exp:cartthrob:item_options entry_id="{entry_id}" parse="inward"}

//Grab the list and format it however you choose…
{exp:stash:get_list name="{segment_1}-Product" scope="site"}
    {exp:stash:get_list:nested name="product_options{entry_id}" scope="site"}
    Label: {option_label}
    Name: {optionname}  Value: {optionvalue} Price: {optionprice}<br>
  • Awesome! Thanks stuartmcd69. I shall give that a go. Looks promising.
    – T2theC
    May 8, 2013 at 18:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.