1

I am using Carthrob with the price modifiers fieldtype.

In the add to cart form everything works as it should. However, when I add an item to the cart, I can't get the price to display, and the cart total is all out of wack.

I have done a variety of tests but can't figure out the issue. Can anyone take a look at the following code and see if I am missing something really obvious?

I have the following code for my add to cart form:

{exp:cartthrob:add_to_cart_form return="enter/checkout"}

    {exp:cartthrob:item_options entry_id="{entry_id}" }
        {select id="purchase-submissions-select" class="standard required"}
            <option {selected} value="{option_value}">{option_name} {price}</option>
        {/select}
    {/exp:cartthrob:item_options}

    <input id="purchase-submissions-submit" type="submit" value="Submit" />

{/exp:cartthrob:add_to_cart_form}

and this as a test in my cart:

{exp:cartthrob:update_cart_form return="/index.php/basket/"}
    {exp:cartthrob:cart_items_info}

        {item_option:fees} - {price} - {quantity}<br />

        {if last_row}
            {cart_total}
        {/if}

    {/exp:cartthrob:cart_items_info}
{/exp:cartthrob:update_cart_form}

P.S I have seen the other thread with a similar problem, and have checked and its not the same issue (i.e no dollar symbols in with the price).

Thank you.

  • I doubt it'll fix it, but it can't hurt. Every example I've seen has cart_items_info on the outside of update_cart_form. Maybe try swapping them. – Jason Varga May 27 '13 at 14:23
  • Also, in cart_items_info. You should use {item_price} instead of {price}. – Jason Varga May 27 '13 at 14:27
1

Have you got your cookies set up in admin/config? I've been going through a similar issue.

Also, check to see if your server I've and computer time are pretty close. It old be that your sessions are a bit lost.

I ran through these: http://cartthrob.com/docs/pages/troubleshooting/#add-to-cart-problems

You may well have seen this already.

Are ou using msm at all? Or Stash?

Lastly, it's a long shot, but add parse="inward" on your item_options. It could be that it's not parsing right.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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