tags:

views:

28

answers:

1

hi, where can I change the column-layout (2-column left, 2-column right etc) of the default contact page in Magento?

thanks

+1  A: 

First, determine the "layout handle" for the contact page. If this is the page you're talking about, then your layout handle is

contacts_index_index

Next, find the layout handle in your layout.xml file

<contacts_index_index translate="label">
    <label>Contact Us Form</label>
    <reference name="root">
        <action method="setTemplate"><template>page/2columns-right.phtml</template></action>
        <action method="setHeaderTitle" translate="title" module="contacts"><title>Contact Us</title></action>
    </reference>
    <reference name="content">
        <block type="core/template" name="contactForm" template="contacts/form.phtml"/>
    </reference>
</contacts_index_index>

Change the setTemplate call to reference your template

<reference name="root">
    <action method="setTemplate"><template>page/1column.phtml</template></action>
    <action method="setHeaderTitle" translate="title" module="contacts"><title>Contact Us</title></action>
</reference>

Alternately, add the handle reference to your local.xml file. The local.xml file is applied last, so whatever goes in there "wins"

<layout>
    <contacts_index_index>
        <reference name="root">
            <action method="setTemplate"><template>page/2columns-left.phtml</template></action>    
        </reference>
    </contacts_index_index>
</layout>   
Alan Storm
@Alan Storm - thank you.
pixeltocode