This is my code:

    <move element="navigation.sections" destination="page.header" />

But the navigation bar disappears then. Whats wrong here?


Solution was to use header.container. Found it via console:

grep -rl "navigation.sections" * to find out where this gets injected, because its close to the desired destination.

nano vendor/magento/module-theme/view/frontend/layout/default.xml to find the name of the container in which it gets injected. Suprise - its header.container instead of page.header.

 <move element="navigation.sections" destination="header.container" />

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.