Magento 2: Disable default header and add custom header content The 2019 Stack Overflow Developer Survey Results Are Inhow does magento generate the content of store link (block name=store.links )in the mobile viewMagento 2 Add block to custom layout via admin panel widgetCustom page layoutHow do I add a template into the header panel? Magento-2.1.7 Porto TemplateHow to Add/Remove Top Links for logged-in/logged-out Users in Magento 2.1How to add title to header without breaking search boxMove/Push page.main.title block into Breadcrumbs Magento2Completely removing the <ul> element at the top that pageRe-position just the welcome messageMagento 2 : How to move the search box next to logo title [SOLVED]
Is an up-to-date browser secure on an out-of-date OS?
Why is my custom API endpoint not working?
Which Sci-Fi work first showed weapon of galactic-scale mass destruction?
Is there any way to tell whether the shot is going to hit you or not?
How to answer pointed "are you quitting" questioning when I don't want them to suspect
How to obtain Confidence Intervals for a LASSO regression?
Are there incongruent pythagorean triangles with the same perimeter and same area?
What does ひと匙 mean in this manga and has it been used colloquially?
Does a dangling wire really electrocute me if I'm standing in water?
Did 3000BC Egyptians use meteoric iron weapons?
Geography at the pixel level
If I score a critical hit on an 18 or higher, what are my chances of getting a critical hit if I roll 3d20?
Is there a symbol for a right arrow with a square in the middle?
Apparent duplicates between Haynes service instructions and MOT
What do hard-Brexiteers want with respect to the Irish border?
Can someone be penalized for an "unlawful" act if no penalty is specified?
Protecting Dualbooting Windows from dangerous code (like rm -rf)
Is a "Democratic" Feudal System Possible?
Does the shape of a die affect the probability of a number being rolled?
What is the formula behind each level spell slot progression that I can use in a spreadsheet?
I see my dog run
Identify boardgame from Big movie
"as much details as you can remember"
What does Linus Torvalds mean when he says that Git "never ever" tracks a file?
Magento 2: Disable default header and add custom header content
The 2019 Stack Overflow Developer Survey Results Are Inhow does magento generate the content of store link (block name=store.links )in the mobile viewMagento 2 Add block to custom layout via admin panel widgetCustom page layoutHow do I add a template into the header panel? Magento-2.1.7 Porto TemplateHow to Add/Remove Top Links for logged-in/logged-out Users in Magento 2.1How to add title to header without breaking search boxMove/Push page.main.title block into Breadcrumbs Magento2Completely removing the <ul> element at the top that pageRe-position just the welcome messageMagento 2 : How to move the search box next to logo title [SOLVED]
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I have created a custom header container and placed inside
app/design/Foo/bar/Magento_Theme/templates/html/header.phtml
Now the content I need is showing up, but also displaying default header contents link links, welcome message, search, logo and titles.
I tried removing them by remove="true" in frontend default.xml, it removes my custom design as well.
Please correct me or let me know how I can use a custom header. Right way of doing it. Thanks
magento2 layout custom phtml header
add a comment |
I have created a custom header container and placed inside
app/design/Foo/bar/Magento_Theme/templates/html/header.phtml
Now the content I need is showing up, but also displaying default header contents link links, welcome message, search, logo and titles.
I tried removing them by remove="true" in frontend default.xml, it removes my custom design as well.
Please correct me or let me know how I can use a custom header. Right way of doing it. Thanks
magento2 layout custom phtml header
add a comment |
I have created a custom header container and placed inside
app/design/Foo/bar/Magento_Theme/templates/html/header.phtml
Now the content I need is showing up, but also displaying default header contents link links, welcome message, search, logo and titles.
I tried removing them by remove="true" in frontend default.xml, it removes my custom design as well.
Please correct me or let me know how I can use a custom header. Right way of doing it. Thanks
magento2 layout custom phtml header
I have created a custom header container and placed inside
app/design/Foo/bar/Magento_Theme/templates/html/header.phtml
Now the content I need is showing up, but also displaying default header contents link links, welcome message, search, logo and titles.
I tried removing them by remove="true" in frontend default.xml, it removes my custom design as well.
Please correct me or let me know how I can use a custom header. Right way of doing it. Thanks
magento2 layout custom phtml header
magento2 layout custom phtml header
edited Jul 23 '17 at 14:03
sv3n
9,96162457
9,96162457
asked Jul 23 '17 at 13:52
GoSmashGoSmash
1011
1011
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
To create a custom header, you must create a default.xml layout in design/fontend//default/Magento-Theme/layout
In this layout you can remove blocks you don't want.
The original template in Magento is in app/code/Magento/Theme/view/frontend/layout/default.xml
To remove a block just write :
or
It depends on which block. Some blocks are necessary to Magento, for example because they have some important js files include. So you can not displayed them but not remove.
add a comment |
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%2f186034%2fmagento-2-disable-default-header-and-add-custom-header-content%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
To create a custom header, you must create a default.xml layout in design/fontend//default/Magento-Theme/layout
In this layout you can remove blocks you don't want.
The original template in Magento is in app/code/Magento/Theme/view/frontend/layout/default.xml
To remove a block just write :
or
It depends on which block. Some blocks are necessary to Magento, for example because they have some important js files include. So you can not displayed them but not remove.
add a comment |
To create a custom header, you must create a default.xml layout in design/fontend//default/Magento-Theme/layout
In this layout you can remove blocks you don't want.
The original template in Magento is in app/code/Magento/Theme/view/frontend/layout/default.xml
To remove a block just write :
or
It depends on which block. Some blocks are necessary to Magento, for example because they have some important js files include. So you can not displayed them but not remove.
add a comment |
To create a custom header, you must create a default.xml layout in design/fontend//default/Magento-Theme/layout
In this layout you can remove blocks you don't want.
The original template in Magento is in app/code/Magento/Theme/view/frontend/layout/default.xml
To remove a block just write :
or
It depends on which block. Some blocks are necessary to Magento, for example because they have some important js files include. So you can not displayed them but not remove.
To create a custom header, you must create a default.xml layout in design/fontend//default/Magento-Theme/layout
In this layout you can remove blocks you don't want.
The original template in Magento is in app/code/Magento/Theme/view/frontend/layout/default.xml
To remove a block just write :
or
It depends on which block. Some blocks are necessary to Magento, for example because they have some important js files include. So you can not displayed them but not remove.
answered Jul 23 '17 at 16:12
MarialenaMarialena
111
111
add a comment |
add a comment |
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%2f186034%2fmagento-2-disable-default-header-and-add-custom-header-content%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