Building pages with Layouts
Exponential Layouts arranges pages from blocks. A layout decides what a page is made of and where each part goes; the content items still hold the text and images. This page is for editors and site builders who arrange pages; the Layouts tab is shown only to roles that may work with layouts.
A page arranged by a layout: zones with blocks such as a hero, lists of articles and teasers.
Layouts, zones, blocks and mappings
- A layout is the plan of a page, for example Landing Page / Fitness.
- It has zones: areas such as left and right, or header, main and footer. The layout type (one column, two columns, sidebar left, hero with three columns ...) decides which zones there are.
- Each zone holds blocks, one under the other: a title, rich text, an image, a list of articles, a gallery, a hero banner and many more.
- A mapping, also called a rule, decides on which pages a layout is used: one page, every page of a class, or a part of the tree.
- A shared layout holds blocks that many pages use, such as the header and footer. Other layouts link a zone to it instead of copying the blocks.
Who can do this
Users whose role has the policies of the module explayouts_ui: read to see layouts and mappings, edit to create and change them, and transfer_export and transfer_import to move layouts between installations.
Find a layout
The Layouts tab opens the Layouts Dashboard: the numbers of layouts, zones, blocks, rules and collections, the recently changed layouts, and the buttons New layout, Layouts and Rules.
The Layouts tab opens the dashboard: figures, the recently changed layouts and buttons for new layouts and the mappings.
Layouts lists every layout with its identifier, type, status and date. Open edits it in the editor, Preview shows it.
Layouts: each layout with its type and status, Open to edit it in the editor, and Preview.
Build a page
- Press New layout, choose a Layout type, give it a Name and press Create layout. The editor opens with the empty zones of that type.
- Press Add a block (the plus button). The block types appear in groups: Basic (title, text, button or link, rich text, image, Markdown ...), Components, Listing, Gallery, Containers and Placeholders. Drag one into a zone.
- Click the block to select it. On the right, Content sets what it shows, for example which items a list shows and how many, chosen with the content browser; Design sets how it looks, such as its view type and style.
- Repeat for every block. Drag a block by its handle to move it; its menu has Duplicate block and Delete block.
- Press Publish layout.
You always work on a draft. Opening a published layout makes a draft of it, and the site keeps showing the published layout until you publish.
| Button | What it does |
|---|---|
| Publish layout | Publishes the draft and closes the editor. Pages that use the layout show it at once. |
| Publish and continue editing | Publishes and keeps the editor open with a new draft. |
| Save draft and close | Keeps the draft for later; the published layout is unchanged. |
| Discard | Throws the draft away, after you confirm. |
| Cancel | Leaves the editor; the draft stays. |
Decide which pages use a layout
Rules on the dashboard, or Layout mappings in the left column, lists the mappings. Each says its layout, whether it is enabled, its Targets (a location, a subtree, a module page) and its Conditions (for example a content type or a siteaccess). The first enabled mapping by priority whose targets and conditions match a page wins. New mapping adds one.
Layout mappings decide which pages use which layout: each has its targets, its conditions and whether it is enabled.
An item's Layouts tab in Content structure shows the layout its page uses and the mappings that apply to it.
What can go wrong
- The page still looks the same. The layout has no mapping for that page, or another mapping comes first.
- A block is empty on the site. Its content is hidden, in the trash, or not readable for visitors.
- Every page changed. You changed a shared layout such as the header and footer. Discard the draft if that was not intended.
- Visitors do not see the change. Where the site does not clear its caches by itself, the editor asks after publishing; choose Clear caches.
Read more
- The layouts editor, in the help center.
- How do I build a page with Layouts?
Contributors
- Graham Brookins Updated Maintainer
Comments
Add a comment