changed layout on the cart and the writing to table