How to outsource backend layouts into an external file

Save your backend layouts to an external file, for example „grid.txt“:

mod.web_layout.BackendLayouts{
    default {
        title = Default
        config{
            backend_layout {
                colCount = 2
                rowCount = 2
                rows {
                    1 {
                        columns {
                            1 {
                                name = Slider
                                colspan = 2
                                colPos = 1
                            }
                        }
                    }
                    2 {
                        columns {
                            1 {
                                name = Sidebar
                                colPos = 2
                            }
                            2 {
                                name = Content
                                colPos = 0
                            }
                        }
                    }
                }
            }
        }
    }
}

Add this to your PAGETS Config:

<INCLUDE_TYPOSCRIPT: source="FILE:fileadmin/customer-page/grid.txt">

Be the first to comment

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.