magento2 -custom layout file not loading Planned maintenance scheduled April 23, 2019 at 23:30...
White walkers, cemeteries and wights
Is there hard evidence that the grant peer review system performs significantly better than random?
Why is it faster to reheat something than it is to cook it?
Most effective melee weapons for arboreal combat? (pre-gunpowder technology)
Why datecode is SO IMPORTANT to chip manufacturers?
Tips to organize LaTeX presentations for a semester
Why not use the yoke to control yaw, as well as pitch and roll?
what is the log of the PDF for a Normal Distribution?
Simple Http Server
I can't produce songs
A proverb that is used to imply that you have unexpectedly faced a big problem
Why not send Voyager 3 and 4 following up the paths taken by Voyager 1 and 2 to re-transmit signals of later as they fly away from Earth?
AppleTVs create a chatty alternate WiFi network
What is the difference between a "ranged attack" and a "ranged weapon attack"?
Co-worker has annoying ringtone
Is it dangerous to install hacking tools on my private linux machine?
Trying to understand entropy as a novice in thermodynamics
Can you force honesty by using the Speak with Dead and Zone of Truth spells together?
Rationale for describing kurtosis as "peakedness"?
GDP with Intermediate Production
The test team as an enemy of development? And how can this be avoided?
Google .dev domain strangely redirects to https
How to change the tick of the color bar legend to black
How many time has Arya actually used Needle?
magento2 -custom layout file not loading
Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern)
Announcing the arrival of Valued Associate #679: Cesar Manara
Unicorn Meta Zoo #1: Why another podcast?Magento custom module - cannot load layout file via XMLLoading Custom Blocks and Layoutsmagento 2 captcha not rendering if I override layout xmlmagento2 unable to override custom search engine- getting blank pagemagento2 toolbar.phtml issue-not overridingCatalog Category not loading with pagerUpdate block arguemnts in xml file (Recommended way not working)Extend admin/login.phtml: Invalid template fileCreate empty page on custom admin url
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
i have followed the below link in order to get check if our custom layout xml file is loaded or not using the event: layout_generate_blocks_after
In the log file i just get:
2016-06-29T11:07:40+00:00 INFO (6):
<layout/>
which should actually load my custom layout file :
catalogsearch_catalogsearch_resultcontroller.xml
Could any1 please help why my layout file is not loading.
UPDATED: LAYOUT file catalogsearch_catalogsearch_resultcontroller.xml
controller path:
VendorModuleControllerCatalog
VendorModuleControllerCatalogSearch
VendorModuleControllerCatalogSearchResult.php
VendorModuleControllerCatalogSearchResultController.php
VendorModuleviewfrontendlayoutcatalogsearch_catalogsearch_resultcontroller.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="catalogsearch.leftnav"><arguments>
<argument name="setTemplate" xsi:type="string">VendorModule::search/filter.phtml</argument>
</arguments>
</referenceBlock>
<referenceBlock name="product_searchlist_toolbar">
<arguments>
<argument name="template" xsi:type="string">VendorModule::toolbar/toolbar.phtml</argument>
</arguments>
</referenceBlock>
</body>
Above xml was replicated from 1x code which was as :
<?xml version="1.0"?>
<layout version="0.1.0">
<catalogsearch_result_index>
<reference name="catalogsearch.leftnav">
<action method="setTemplate">
<setTemplate>/filter.phtml</setTemplate>
</action>
</reference>
<reference name="content">
<reference type="catalogsearch/result" name="search.result">
<reference name="search_result_list">
<reference name="product_list_toolbar">
<action method="setTemplate">
<template>toolbar.phtml</template>
</action>
</reference>
</reference>
</reference>
</reference>
</catalogsearch_result_index>
</layout>
system.log :
Cache file with merged layout: LAYOUT_frontend_STORE1_3d41d8cd98f00b204e9800998ecf8427e and handles : Please correct the XML data and try again. [] []
magento2 layout error blocks
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
i have followed the below link in order to get check if our custom layout xml file is loaded or not using the event: layout_generate_blocks_after
In the log file i just get:
2016-06-29T11:07:40+00:00 INFO (6):
<layout/>
which should actually load my custom layout file :
catalogsearch_catalogsearch_resultcontroller.xml
Could any1 please help why my layout file is not loading.
UPDATED: LAYOUT file catalogsearch_catalogsearch_resultcontroller.xml
controller path:
VendorModuleControllerCatalog
VendorModuleControllerCatalogSearch
VendorModuleControllerCatalogSearchResult.php
VendorModuleControllerCatalogSearchResultController.php
VendorModuleviewfrontendlayoutcatalogsearch_catalogsearch_resultcontroller.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="catalogsearch.leftnav"><arguments>
<argument name="setTemplate" xsi:type="string">VendorModule::search/filter.phtml</argument>
</arguments>
</referenceBlock>
<referenceBlock name="product_searchlist_toolbar">
<arguments>
<argument name="template" xsi:type="string">VendorModule::toolbar/toolbar.phtml</argument>
</arguments>
</referenceBlock>
</body>
Above xml was replicated from 1x code which was as :
<?xml version="1.0"?>
<layout version="0.1.0">
<catalogsearch_result_index>
<reference name="catalogsearch.leftnav">
<action method="setTemplate">
<setTemplate>/filter.phtml</setTemplate>
</action>
</reference>
<reference name="content">
<reference type="catalogsearch/result" name="search.result">
<reference name="search_result_list">
<reference name="product_list_toolbar">
<action method="setTemplate">
<template>toolbar.phtml</template>
</action>
</reference>
</reference>
</reference>
</reference>
</catalogsearch_result_index>
</layout>
system.log :
Cache file with merged layout: LAYOUT_frontend_STORE1_3d41d8cd98f00b204e9800998ecf8427e and handles : Please correct the XML data and try again. [] []
magento2 layout error blocks
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
1
Could you please post the code of your layout file ?
– Raphael at Digital Pianism
Jun 29 '16 at 11:18
i have updated the layout file
– Sushivam
Jun 29 '16 at 11:35
layout ending tag is already there, i just forgot to give tab while adding question. and its magento1x code which i had replicated to magento2x layout file where the issue is
– Sushivam
Jun 29 '16 at 11:42
See my updated answer
– Raphael at Digital Pianism
Jun 29 '16 at 11:45
add a comment |
i have followed the below link in order to get check if our custom layout xml file is loaded or not using the event: layout_generate_blocks_after
In the log file i just get:
2016-06-29T11:07:40+00:00 INFO (6):
<layout/>
which should actually load my custom layout file :
catalogsearch_catalogsearch_resultcontroller.xml
Could any1 please help why my layout file is not loading.
UPDATED: LAYOUT file catalogsearch_catalogsearch_resultcontroller.xml
controller path:
VendorModuleControllerCatalog
VendorModuleControllerCatalogSearch
VendorModuleControllerCatalogSearchResult.php
VendorModuleControllerCatalogSearchResultController.php
VendorModuleviewfrontendlayoutcatalogsearch_catalogsearch_resultcontroller.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="catalogsearch.leftnav"><arguments>
<argument name="setTemplate" xsi:type="string">VendorModule::search/filter.phtml</argument>
</arguments>
</referenceBlock>
<referenceBlock name="product_searchlist_toolbar">
<arguments>
<argument name="template" xsi:type="string">VendorModule::toolbar/toolbar.phtml</argument>
</arguments>
</referenceBlock>
</body>
Above xml was replicated from 1x code which was as :
<?xml version="1.0"?>
<layout version="0.1.0">
<catalogsearch_result_index>
<reference name="catalogsearch.leftnav">
<action method="setTemplate">
<setTemplate>/filter.phtml</setTemplate>
</action>
</reference>
<reference name="content">
<reference type="catalogsearch/result" name="search.result">
<reference name="search_result_list">
<reference name="product_list_toolbar">
<action method="setTemplate">
<template>toolbar.phtml</template>
</action>
</reference>
</reference>
</reference>
</reference>
</catalogsearch_result_index>
</layout>
system.log :
Cache file with merged layout: LAYOUT_frontend_STORE1_3d41d8cd98f00b204e9800998ecf8427e and handles : Please correct the XML data and try again. [] []
magento2 layout error blocks
i have followed the below link in order to get check if our custom layout xml file is loaded or not using the event: layout_generate_blocks_after
In the log file i just get:
2016-06-29T11:07:40+00:00 INFO (6):
<layout/>
which should actually load my custom layout file :
catalogsearch_catalogsearch_resultcontroller.xml
Could any1 please help why my layout file is not loading.
UPDATED: LAYOUT file catalogsearch_catalogsearch_resultcontroller.xml
controller path:
VendorModuleControllerCatalog
VendorModuleControllerCatalogSearch
VendorModuleControllerCatalogSearchResult.php
VendorModuleControllerCatalogSearchResultController.php
VendorModuleviewfrontendlayoutcatalogsearch_catalogsearch_resultcontroller.xml
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="catalogsearch.leftnav"><arguments>
<argument name="setTemplate" xsi:type="string">VendorModule::search/filter.phtml</argument>
</arguments>
</referenceBlock>
<referenceBlock name="product_searchlist_toolbar">
<arguments>
<argument name="template" xsi:type="string">VendorModule::toolbar/toolbar.phtml</argument>
</arguments>
</referenceBlock>
</body>
Above xml was replicated from 1x code which was as :
<?xml version="1.0"?>
<layout version="0.1.0">
<catalogsearch_result_index>
<reference name="catalogsearch.leftnav">
<action method="setTemplate">
<setTemplate>/filter.phtml</setTemplate>
</action>
</reference>
<reference name="content">
<reference type="catalogsearch/result" name="search.result">
<reference name="search_result_list">
<reference name="product_list_toolbar">
<action method="setTemplate">
<template>toolbar.phtml</template>
</action>
</reference>
</reference>
</reference>
</reference>
</catalogsearch_result_index>
</layout>
system.log :
Cache file with merged layout: LAYOUT_frontend_STORE1_3d41d8cd98f00b204e9800998ecf8427e and handles : Please correct the XML data and try again. [] []
magento2 layout error blocks
magento2 layout error blocks
edited May 3 '18 at 0:39
Rohan Hapani
7,01631865
7,01631865
asked Jun 29 '16 at 11:12
SushivamSushivam
1,26021547
1,26021547
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 4 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
1
Could you please post the code of your layout file ?
– Raphael at Digital Pianism
Jun 29 '16 at 11:18
i have updated the layout file
– Sushivam
Jun 29 '16 at 11:35
layout ending tag is already there, i just forgot to give tab while adding question. and its magento1x code which i had replicated to magento2x layout file where the issue is
– Sushivam
Jun 29 '16 at 11:42
See my updated answer
– Raphael at Digital Pianism
Jun 29 '16 at 11:45
add a comment |
1
Could you please post the code of your layout file ?
– Raphael at Digital Pianism
Jun 29 '16 at 11:18
i have updated the layout file
– Sushivam
Jun 29 '16 at 11:35
layout ending tag is already there, i just forgot to give tab while adding question. and its magento1x code which i had replicated to magento2x layout file where the issue is
– Sushivam
Jun 29 '16 at 11:42
See my updated answer
– Raphael at Digital Pianism
Jun 29 '16 at 11:45
1
1
Could you please post the code of your layout file ?
– Raphael at Digital Pianism
Jun 29 '16 at 11:18
Could you please post the code of your layout file ?
– Raphael at Digital Pianism
Jun 29 '16 at 11:18
i have updated the layout file
– Sushivam
Jun 29 '16 at 11:35
i have updated the layout file
– Sushivam
Jun 29 '16 at 11:35
layout ending tag is already there, i just forgot to give tab while adding question. and its magento1x code which i had replicated to magento2x layout file where the issue is
– Sushivam
Jun 29 '16 at 11:42
layout ending tag is already there, i just forgot to give tab while adding question. and its magento1x code which i had replicated to magento2x layout file where the issue is
– Sushivam
Jun 29 '16 at 11:42
See my updated answer
– Raphael at Digital Pianism
Jun 29 '16 at 11:45
See my updated answer
– Raphael at Digital Pianism
Jun 29 '16 at 11:45
add a comment |
1 Answer
1
active
oldest
votes
It is because your file is not properly named.
It should be catalogsearch_result_index.xml
instead of catalogsearch_catalogsearch_resultcontroller.xml
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
1
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
|
show 2 more comments
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "479"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f123385%2fmagento2-custom-layout-file-not-loading%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
It is because your file is not properly named.
It should be catalogsearch_result_index.xml
instead of catalogsearch_catalogsearch_resultcontroller.xml
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
1
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
|
show 2 more comments
It is because your file is not properly named.
It should be catalogsearch_result_index.xml
instead of catalogsearch_catalogsearch_resultcontroller.xml
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
1
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
|
show 2 more comments
It is because your file is not properly named.
It should be catalogsearch_result_index.xml
instead of catalogsearch_catalogsearch_resultcontroller.xml
It is because your file is not properly named.
It should be catalogsearch_result_index.xml
instead of catalogsearch_catalogsearch_resultcontroller.xml
edited Jun 29 '16 at 11:45
answered Jun 29 '16 at 11:37
Raphael at Digital PianismRaphael at Digital Pianism
55.2k22124280
55.2k22124280
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
1
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
|
show 2 more comments
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
1
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
thats the magento1x xml file, which i forgot to tab while adding question...</layout> is already there.
– Sushivam
Jun 29 '16 at 11:39
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
But i dont have result/index in my custom module... i have the controller path as shown... should i still give catalogsearch_result_index.xml name instead, with just content replaced
– Sushivam
Jun 29 '16 at 11:51
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
i followed... routerfrontname_controlleraction_controllername.xml for naming the layout of my custom xml... is it rite? or should i use the default magentos catalogsearch_result_index
– Sushivam
Jun 29 '16 at 11:57
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
please see my system .log says in my updated answer
– Sushivam
Jun 29 '16 at 11:58
1
1
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
Did you ever get an answer to this?
– LM_Fielding
Aug 22 '16 at 10:08
|
show 2 more comments
Thanks for contributing an answer to Magento Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f123385%2fmagento2-custom-layout-file-not-loading%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
Could you please post the code of your layout file ?
– Raphael at Digital Pianism
Jun 29 '16 at 11:18
i have updated the layout file
– Sushivam
Jun 29 '16 at 11:35
layout ending tag is already there, i just forgot to give tab while adding question. and its magento1x code which i had replicated to magento2x layout file where the issue is
– Sushivam
Jun 29 '16 at 11:42
See my updated answer
– Raphael at Digital Pianism
Jun 29 '16 at 11:45