Curtains & Magento


Every Magento build is a learning experience. Very few products are straightforward enough to not need some customization of the default Magento setup. Perfect Curtains was no different in this regard.

Curtains create two complications. Firstly, there is the potential for an exponential explosion in the number of simple products, if the number of size intervals aren’t kept to a minimum. (Fortunately, the price matrix was kept down to a size of 15 – much more manageable than a previous experience with 400!) Each curtain is a configurable product with the various intervals being the simple products. The customer inputs his/her exact dimensions and an AJAX call selects the next appropriate size interval. Fairly straightforward once you know what you’re doing.

Secondly, curtains have a lot of interdependent custom options. There are headings and poles and rails, etc. Many of them can affect the final dimensions that the merchant needs to know and can also affect the price in other ways. So a very customized product order form needed to be created to bring the customer gradually through the ordering process, ensuring that nothing was too complicated, whilst ensuring that all of the necessary information was provided.

With some experience in complex Magento order forms of late, I’ve decided that building them via static HTML to the point where the user experience is satisfactory before dealing with how they will integrate with Magento is the best way to go. In the case of curtains, where the heading chosen by the customer determined which product would be purchased (and hence which product ID etc, should be sent to the cart) it was always going to be necessary to do an AJAX call to determine the exact product ID. So if we’re going to do an AJAX call at this point, why not pull out all the custom option IDs at the same time, dynamically putting them into the names and values of the input fields of the static HTML form?!

The other learning area on this project was Related Products. Two things:

  1. It’s pretty useless having a configurable product as a related product in Magento. You can’t configure them by default in the related products box so you can’t add them automatically at the same time as the main product. In the example of the Roman Blinds Rail in Perfect Curtains, I had to add in the appropriately sized Roman Blind Rail at the time when the customer updates the quote for their Roman Blind after they have input their desired dimensions. It’s not perfect, as the customer could simply click “add to cart”.
  2. Related Products don’t have to be related in the Magento backend. It’s not possible by default to import related products via a CSV. So the thought of going through the Magento backend and associating all the related products didn’t inspire me. Until I found out that any product can be added to the shopping cart as a “related product”. All that is required is an input field with a name of “related_products” and the product ID as the value! Sweet.
Alan Morkan
Alan Morkan |