9

In magento on cart page there is a javascript function call decorateTable('shopping-cart-table'). For what is used the function decorateTable?

13

The decorateTable function is used to add some classes on the tr and td elements of a table. Classes like odd even first last for the tr elements and last on the td elements. It's easier this way then to do it from PHP.
After adding these classes you can easily create css styles for each one of the added classes and make the table rows and columns stand out in the crowd.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.