The layout of the product information page in the magento default template is displayed in two columns with the right column. How can I change the layout to display the product information page with the left or three or one columns? The following is a simple method for implementation.
The default layout preview is shown below:
Change to the effect of the two columns with the left column:
Effect after being changed to three columns:
Change to a column:
This effect is easy to implement. First you need to open the catalog. xml file
Version 1.3
APP> Design> frontend> default> deault> layout> catalog. xml
Version 1.4
APP> Design> frontend> base> deault> layout> catalog. xml
There are about 190th lines of code in "Product View ".
? View code PHP
<action method="setTemplate"><template>page/2columns-right.phtml</template></action>
If you want to change it to the effect of the two columns with the left column, replace 2columns-right.phtml with 2columns-left.phtml.
If you want to change the effect to three columns, replace 2columns-right.phtml with 3columns. phtml.
If you want to change the result to a column, replace 2columns-right.phtml with 1column. phtml.
Don't worry. After modifying the above Code, you must refresh the cache, especially the layouts cache, so that the front-end can achieve the effect.
Of course, there is also a way to change the layout of the product page, open magento background => catalog => Manage products to find a product on a product page that you need to modify to open and edit,
Click the design tag of the product information on the left to select page layout,
However, this method can only modify the layout of a single product page, which is not conducive to the modification of the product page. However, you can also use batch upload to add a column to the CSV table of the batch upload product. The added field name is "page_layout ", the value of a field is "3 columns", "2 columns with Left bar", "2 columns with right bar", or "1 column"