I was assigned to work on a shopping cart for an online clothing retailer. By the time this client approached us, it was just a few days before Christmas, and their shopping cart had a big problem.
Say for example that you added a blue polka dot shirt of size “large” to your shopping cart. Then, after continued browsing through the online catalog, you decide that you want a “small” blue polka dot shirt. The problem was that after adding this shirt of size “small”, your shopping cart would contain two (correct) shirts of size small (wrong). Obviously, you should have a small shirt and a large shirt.
This cart was indexing items by product ID, and not accommodating for multiple sizes.
Our solution for them was a cart structured to be unique on product ID and size. Short, Sweet, and Simple. S, S, & S the solution may have been, it still took a long time to develop because of the fact that there was no sandbox (development) environment and the system was in the process of taking orders as we were developing. Some would say that’s a huge no-no, but the issue had to be addressed. With the utmost planning and preparation, the coding was done and no order processes were interfered with.
On a humorous note, I charged my credit card a $xxx.xx item (yes, in the hundreds of dollars) to test the new shopping cart’s functionality. When doing e-commerce development, make sure to obtain test credit card numbers. Most online payment processors should have these readily available for developers.




