Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Order of Operations


Guest

Recommended Posts

Posted

When changing the price of an item, the order of operations does not work correctly.

 

An example: i sell vehicle graphics. if the purchaser wants a drop shadow, it is usually a % of the cost, because the cost is determined by length of graphic and the increase is determined that way.

 

I have the multiplication setup so i can do such things, but the order of operations is off. if i have 2 of the same item in the cart, it multiplies, say its 50% increase, to original price, say $100, then adds the second item.

 

This is how it should be:

($100 x 2 items) x 50% increase for additional options = $300

 

It is currently being calculated as:

($100 x 50%) + $100 second item = $250

 

the total comes out to $250 for the two items rather than $300.

 

Anyone know of a contribution that may already fix this?

 

hope i have explained it well enough for everyone to understand...

 

Ryan

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...