Search code examples
magento-1.9

What is block type core/text_list in magento?


What is core/text_list below and how does it work? I am checking the core folder but can't find explanation about how text_list works.

app/design/frontend/base/default/template/core 

<block type="core/text_list" name="before_body_end" as="before_body_end" translate="label">
            <label>Page Bottom</label>
            <block type="page/html_cookieNotice" name="global_cookie_notice" as ="global_cookie_notice" template="page/html/cookienotice.phtml" before="-" />
        </block>

Solution

  • Its a structural block. Blocks of type core/text_list will automatically render all its children without the need to call the getChildHtml() method. You can see the relevant class here.

    The translate attribute contains a space-delimited list of tag names that needs to be translated, <label> in your example.

    A new block cookieNotice is being added before the body end using the template you provided to it page/html/cookienotice.phtml