Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cant set HtmlTag to "nav" #2549

Closed
refaelgold opened this issue Nov 28, 2015 · 2 comments
Closed

Cant set HtmlTag to "nav" #2549

refaelgold opened this issue Nov 28, 2015 · 2 comments
Assignees

Comments

@refaelgold
Copy link

Hey,
i try to make a menu like in HTML5 and use the nav element

        <container name="header.container" as="header_container" label="Page Header Container"  htmlTag="nav" htmlClass="navbar navbar-default" before="main.content"/>

i get an error

a:4:{i:0;s:167:"Html tag "nav" is forbidden for usage in containers. Consider to use one of the allowed: dd, div, dl, fieldset, main, header, footer, ol, p, section, table, tfoot, ul."

you have an idea why nav is forbidden? it will be fixed soon?

@victorgugo
Copy link
Contributor

@refaelgold , thank you for reporting the issue. We created internal one MAGETWO-46295 to fix the problem.
As a temporary workaround you can use block Magento\Framework\View\Element\Template with custom template instead of container, for example:
<block class="Magento\Framework\View\Element\Template" template="Magento_ModuleName::path/to/template.phtml"/>

@shiftedreality
Copy link
Member

Fix was merged to develop branch. Closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants