How to change logo location in Magento CE 2.0.2 ?

I want to move logo to header.panel block.

Tried to do it through layout/xml but that only provides changing position (before/after).

Any help appreciated.

有帮助吗?

解决方案

You can use this approach to move a block:

   <move element="logo" destination="header.panel" />

with attributes "before" or "after".

You can use "before" = "-" to place your element at the very begin of the destination and "after" = "-" to place your element at the very end of the destination. Look at the source code for examples.

You can find also another approach. This one is about using actions "unsetChild" and "insert".

许可以下: CC-BY-SA归因
scroll top