1

Is it possible to move the page title on cms pages to the left column of a 2 column left layout?

But, purely using local.xml and not editing the templates?

2

Yes of course, bu not page title, you can move content heading. In that case local.xml cannot affect to cms page, because of it is loaded before cms.xml. You should edit cms.xml as following:

<cms_page translate="label">
    <label>CMS Pages (All)</label>
    <reference name="left">
        <block type="core/template" name="page_content_heading" template="cms/content_heading.phtml" before="tags_popular"/>
        <remove name="catalog.compare.sidebar"/>
    </reference>
    <reference name="content">
         <block type="page/html_wrapper" name="cms.wrapper" translate="label">
             <label>CMS Content Wrapper</label>
             <action method="setElementClass">
                  <value>std</value>
             </action>
             <block type="cms/page" name="cms_page"/>
         </block>
    </reference>
</cms_page>

You should change layout of cms page via admin.

  • This answer does not follow Magento best practices for an upgrade compatible site. Also, it is incorrect in stating that local.xml is loaded before cms.xml. local.xml is always the last layout XML file to be loaded the theme. This is intentional so that you can contain all your layout updates within here and not have to copy base layout files to your local theme. Please see my answer, for an upgrade compatible method. – Darren Felton Oct 31 '14 at 17:55
1

mageUz's answer does not follow best practices for keeping your Magento installation upgrade friendly. You should avoid editing cms.xml or any of the other base xml files.

A better way to do this would be the following in app/design/frontend/PACKAGE_NAME/THEME_NAME/layout/local.xml

<cms_page>
    <reference name="left">
        <action method="setChild">
            <name>page_content_heading</name>
        </action>
    </reference>
    <reference name="content">
        <action method="unsetChild">
            <name>page_content_heading</name>
        </action>
    </reference>
</cms_page>

Additionally, this can be done on a per page basis by putting this XML into the "Layout Update XML" field of the Design Tab, when editing pages from the admin. You would just omit the "cms_page" node, and instead just need the two "reference" xml nodes.

  • Is there any reason or circumstance that would prevent this answer from working? I tried doing this but i am seeing no results. I am trying to tke the page title out of the content section and place above the wrapper underneath my breadcrumbs sections. – Travis Michael Heller Sep 4 '15 at 13:48
  • <div class="main"> <div class="col-main"> <?php echo $this->getChildHtml('breadcrumbs') ?> <?php echo $this->getChildHtml('global_messages') ?> <?php echo $this->getChildHtml('content') ?> </div> – Travis Michael Heller Sep 4 '15 at 13:50
  • @TravisMichaelHeller what is your XML? Can you link to something where I can see it? – Darren Felton Sep 4 '15 at 14:04

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.