TYPO3Buddy
TYPO3Buddy is on FacebookTYPO3Buddy is on Twitter
menu

TYPO3 Fluid: Create additional backend layouts

Next, you'll create two additional backend layouts. One for each new content template you have created. Click on list, click on "storage folder" and click on the green plus next to the existing backend layout to add a new backend layout on the root page and end up with:

TYPO3 Fluid tutorial: multiple backend layouts - TYPO3Buddy website tutorial

For the first new backend layout, put "Main 1 column without menu" in the title field, and add the following to the Config field:

backend_layout {
    colCount = 1
    rowCount = 1
    rows {
        1 {
            columns {
                1 {
                    name = Content main (without menu)
                    colPos = 0
                }
            }
        }
    }
}

You'll end up with this:

TYPO3 Edit backend layout - TYPO3Buddy website tutorial

You may have noticed that the Config part of this backend layout is almost exactly the same as the Config part of the existing backend layout with menu! Well, that's correct. The backend layout is the same, both layouts have one row and one content column, but the content template file they link to is different. You will use the backend layout, not only to indicate what backend layout you want to use for a page, but also to indicate which frontend layout will be used for that page! This will be clear in a minute. Hopefully.

First, create another backend layout. Put "Main 2 column without menu" in the title field, and add the following to the Config field:

backend_layout {
    colCount = 2
    rowCount = 1
    rows {
        1 {
            columns {
                1 {
                    name = Content column 1
                    colPos = 1
                }
                2 {
                    name = Content column 2
                    colPos = 2
                }
            }
        }
    }
}

You'll end up with this:

TYPO3 Edit backend layout - TYPO3Buddy website tutorial

A note on backend layouts. Hiding a backend layout doesn't keep TYPO3 from using it. Second, if you have set a general storage folder for your root page, the backend layouts must be placed in this general storage folder. Otherwise they will only be available on the root page; every other page will look for backend layouts in the storage folder.

Please note: if you use the layouts "without menu" for certain pages, these pages won't have a menu when visited on a mobile device. In other words: the user won't be able to navigate to other pages. This is due to the fact that the TYPO3Buddy tutorial once was desktop only.

Next step: update the typoscript "Main template" to use the newly created templates ->

The TYPO3Buddy website is a tutorial to rebuild the TYPO3Buddy website from scratch. You can choose from a TYPO3 Fluid tutorial and a TYPO3 Templavoila tutorial. You'll build TYPO3 websites like you've done so for years!