Certificated magento

3.8) What are blocks used for in Magento?

Blocks are the main design element in Magento. A hierarchy of blocks is used to layout any page in a Magento store. Blocks in Magento divide into two big groups:

Structural Blocks
Content Blocks
 
Programmatically there are no difference between them, but structural blocks are use in Magento to define main areas of a page, while content blocks are used to render a particular area of it.
 
For example, in a typical home page of a Magento Store you may see a (simplified) hierarchy similar to the following:
 
  • Page
    • Header
    •     Login
    •     Cart
    •     Navigation menu
    • Content
    •     Main Banner
    •     Latest Products
    • (Sidebar) Left
    •     Layered navigation
    •     Promo banner
    • Footer
    •     Copyright
    •     Terms and Conditions
Its a very simplified layout and the name are not as it should be in a real store, but Header, Content, Sidebar and Footer would be structural blocks, and everything down them would be content blocks.

0 Bình luận

Trở về
  • 1.12) Set up a cron job
  • 1.12) Set up a cron job

    Let’s start with server setup.   As any complex system, Magento has a lot of tasks that need to be executed...