I have this problem in Drupal Commerce: a line item should change the price of my product, that is based on customizing the users (ex. product base $10 with customization $12, customization is line items).

This is possible working on Rules, but you only see final price after you add the product on cart, I should instead see the price change in ajax so the users see final process before add to cart.

I've not found solutions online. The basic scenario is like this:

  • You buy a shirt based =$10
  • The user customizes the shirt with your name and = $12
  • The user customizes name and logo = $14

I am working with Kickstart 2.0

2 Answers 2


The functionality you're looking for doesn't exist at the moment. I'd describe it as wanting line item field value changes to trigger a refresh of the Add to Cart form and the injected product fields. You can follow this feature request, though I'm not sure it's likely to be addressed soon:



So you have fixed prices and a set of fields per kind of price? Ha! You could setup a line item type per product:


And then create three products:

  1. Shirt, Price $10
  2. Shirt + Name, Price $12, custom line item type: Name
  3. Shirt + Name + Logo, Price $14, custom line item type: Name + Logo

Then create one Product Display node and attach those three products to the display node.

In theory, that should work. Let me know how the "in practice" goes.

EDIT: Here's how to do it, step by step in a video:



  • Hi Josh, I often follow your tutorials and articles. :) I tried to follow the directions in the link you've written but I can not get it to work. There are some changes to the source code to adapt the module? But this solution seems just what I need. I would like to make it work. Do you have an example link? Sep 27, 2014 at 8:33
  • I'll take this idea for a spin on Monday.
    – joshmiller
    Sep 27, 2014 at 15:41
  • Hi Josh, ty for your time. This video is really a good solution for me. I followed all step u say but in kickstart 2 but there is a problem on "Use custom line item type" check box, i check this but drupal not save this check. Oct 7, 2014 at 9:29
  • Yeah, it's important to build on Kickstart 1. Kickstart 2 is more like a demo/proof-of-concept. If you are adding fields to line items, it's likely Kickstart 2 is too opinionated to be flexible enough for your use case.
    – joshmiller
    Oct 7, 2014 at 14:54
  • Oh, ok, really Kickstart 2 is only like a demo? I have done latest 2 e-commerce with K2 and it work well. I can't now switch to K1 coz is too late :( Oct 7, 2014 at 16:38

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.