I'm trying to move the highlighted div
right after the header page div. I'm not sure how I can do this - can someone explain how?
-
Did my answer help? If so, I'd appreciate if you'd consider marking it as the accepted answer by clicking the checkmark next to it...– tjonsDec 7, 2016 at 2:36
1 Answer
Hmm. It sounds like you're not very familiar with Magento's frontend system, so I'll refer you to another answer that I wrote that explains it in detail: https://magento.stackexchange.com/a/135744/5134.
Now, to apply the principles there to your problem, you should use the unsetChild
and insert
methods to remove the block in one place, and insert it in another. I recommend doing this in your theme's local.xml
file, although if this is a module-specific customization, you may want to put it in a layout file specific to your module.
Here's an example of how to remove the block and reinsert it:
<layout>
<reference name="the_parent_block_of_the_main_container_block">
<action method="unsetChild">
<alias>the_alias_of_the_main_container_block</alias>
</action
</reference>
<reference name="the_parent_of_the_header">
<action method="insert">
<blockName>name_of_the_main_container_block</blockName>
</action>
</reference>
</layout>