Sections

Sections are parts of one of the contexts in a template: Print, Email or Web. They contain the main text flow for the contents. In each of the contexts there can be multiple sections. A Print context, for example, may consist of two sections: a covering letter and a policy.

Adding a section

To add a section to a context, right-click the context (Email, Print or Web) on the Resources pane, and then click New section.

It is not possible to use a Template Wizard when adding a section to an existing template.

If an Email context is going to be part of the template, it is recommended to start with an Email Template Wizard; see Creating an Email template with a Wizard. After creating a template, contexts can be added to it, but that can not be done with a wizard.

Editing a section

To open a section, expand the Contexts folder on the Resources pane, expand the respective context (Print, Email or Web) and double-click a section to open it.

Each section can contain text, images and many other elements (see Content elements), including variable data and other dynamic elements (see Personalizing content).

Copying a section

Copying a section, either within the same template or from another template, can only be done manually. You have to copy the source of the HTML file:

  1. Open the section that you want to copy and go to the Source tab in the workspace.
  2. Copy the contents of the Source tab (press Ctrl+A to select everything and then Ctrl+C to copy the selection).
  3. Add a new section (see Adding a section).
  4. Go to the Source tab and paste the contents of the other section here (press Ctrl+V).
  5. When copying a section to another template, add the related source files, such as images, to the other template as well.

Deleting a section

To delete a section:

  • On the Resources pane, expand the Contexts folder, expand the folder of the respective context, right-click the name of the section, and then click Delete.

No backup files are maintained in the template. The only way to recover a deleted section, is to click Undo on the Edit menu, until the deleted section is restored. After closing and reopening the template it is no longer possible to restore the deleted context this way.

Renaming a section

To rename a section:

  • On the Resources pane, expand the Contexts folder, expand the folder of the respective context, right-click the name of the section, and then click Rename.
Sections cannot have an integer as name. The name should always include alphanumeric characters.

Section properties

Which properties apply to a section, depends on the context it is part of. See also: Print sections, Email templates, and Web pages.

To change the properties for a section:

  • On the Resources pane, expand the Contexts folder, expand the folder of the respective context, right-click the name of the section, and then click one of the options.

Applying a style sheet to a section

In order for a style sheet to be applied to a specific section, it needs to be included in that section. There are two ways to do this.

Drag & drop a style sheet

  1. Click and hold the mouse button on the style sheet on the Resources pane.
  2. Move the mouse cursor within the Resources pane to the section to which the style sheet should be applied.
  3. Release the mouse button.

Using the Includes dialog

  1. On the Resources pane, right-click the section, then click Includes.
  2. Choose which CSS files should be applied to this section. You can also change the order in which the CSS files are read. This can have an effect on which CSS rule is applied in the end.

Arranging sections

Changing the order of the sections in a context can have an effect on how they are outputted; see: Print sections, Email templates and Web pages.

To rearrange sections in a context:

  • On the Resources pane, expand the Contexts folder, expand the folder of the respective context, and then drag and drop sections to change the order they are in.
    Alternatively, right-click a section and click Arrange. In the Arrange Sections dialog you can change the order of the sections in the same context by clicking the name of a section and moving it using the Up and Down buttons.

Outputting sections

Which sections are added to the output, depends on the type of context they are in.

When generating output from the Print context, each of the Print sections is added to the output document, one after the other in sequence, for each record. The sections are added to the output in the order in which they appear on the Resources pane. See Generating Print output.

In email and web output, only one section can be executed at a time. The section that will be output is the section that has been set as the 'default'. See Generating Web output and Web pages and Generating Email output and Email templates. The 'default' section is always executed when the template is run using the Create Email Content task in Workflow (see Workflow Help: Create Email Content).

It is, however, possible to include or exclude sections when the output is generated, or to set another section as the 'default', depending on a value in the data. A Control Script can do this; see Control Scripts.

See Generating output to learn how to generate Print documents, Web pages or Email.

 
  • Last Topic Update: 24/01/2017 09:32
  • Last Published: 7/6/2017 : 9:48 AM