Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange
4 Rollback to Revision 2 - Edit approval overridden by post owner or moderator
source | link

In Magento Magento 22.x* we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_themeCustom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

In Magento 2.x we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

In Magento 2.* we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

3 some basic change as per requirement
source | link

In Magento 2Magento 2.*x we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_themeCustom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

In Magento 2.* we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

In Magento 2.x we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

2 added 490 characters in body
source | link

In Magento 2.* we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

In Magento 2.* we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

In Magento 2.* we could extend core layouts using custom theme, for instance, (assuming our custom theme is named Custom/our_theme) if we want to remove header & footer in customer login page we did

app/design/frontend/Custom/our_theme/Magento_Customer/layout/customer_account_login.xml

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceContainer name="footer" remove="true"/>
        <referenceContainer name="header.container" remove="true"/>
    </body>
</page>

However, in Magento 2.3 that way to extend layouts seem to have no effect. The strange thing is we can load CSS changes, override templates, etc... with no problem, so it is clear custom theme is well registered & it is working

But the only way to change layout structure seem to be doing it in a custom module (using layout_load_before event, for instance)

Is this a common issue? I mean, have you faced this in Magento 2.3 here? Or should we assume there is something wrong in our project?

UPDATE

We've seen that applying changes as layout updates then it does work

<layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_layout.xsd">
    <referenceContainer name="footer" remove="true" />
    <referenceContainer name="header.container" remove="true" />
</layout>

What I don't understand is why the first way (including page & body tags) has stopped working

1
source | link