About conditional tags

Sometimes you author different types of content for different output formats using the same FrameMaker document. This document can contain conditional tags and conditional graphics for each type of output. For example, to create both a PDF print version and an HTML Help version of a document, mark the different content for each using condition tags.

You can also use conditional tags to include comments to yourself or to your reviewers. You can hide the comments before you print the final copy.

Conditional tags differ from one version of a document to another. Unconditional text is common to all versions.

You can make any unit of text conditional, from one character to entire sections. Anchored graphics, tables, cross-references, footnotes, markers, and table rows can be conditional. You make an item conditional by applying condition tags.

Two versions of a data sheet: Conditional tags can be used to create two data sheets in one document. The text and graphics common to both data sheets are unconditional. The text and graphics that appear in only one data sheet are assigned a condition tag that identifies the data sheet.
The art and first paragraph contain both conditional and unconditional information.

.Unconditional text.

The condition tags of the current selection (or at the insertion point) appear in parentheses in the Tag area of the status bar.

Tag area of status bar

You can change the appearance of conditional tags so that it’s easy to identify by using condition indicators—style and color changes.

Condition indicators (strikethrough and underline) identify two conditions.

You can view all versions of the document or hide selected versions. You can show or hide condition indicators. Whatever you display appears in the printed document.

Conditional Tags pod

The Conditional Tags pod:
  • Lets you apply and manage conditional tags

  • Displays the tags that are applied

See the video: Conditional Tags Pod.

View full size graphic
Conditional Tags pod
Select the file for which you want to view the conditional tags. You can select either one file or all open files.

Create a new conditional tag

Edit a condition

Delete a condition

Open the Show/Hide Conditional Text pod

Apply the selected (checked) tags to selected content

Uncheck all the conditions (To remove all the conditions from the selected text, click Uncheck All and then click Apply)


Search: As you type, FrameMaker matches the criteria with entries in all the columns of the pod

Clear search

A selected tag for deletion with the whole row highlighted. This is different from selecting a conditional tag to apply where you check the checkbox in the State column in the pod.

States of conditional tags

When you select a piece of content, the Conditional Tags pod displays the three possible states of conditional tags, applied, not applied, and as is, as following:


As per the selected text means

Applied: The conditional tag is applied to the selected content.

Not Applied: The conditional tag is not applied to the selected content.

As is: The conditional tag is applied to a part of the selected content.

To see the state of the various conditional tags as per selected content, see the State column in the Conditional Tags pod.

You can select or deselect the various conditional tags to apply by clicking the check boxes in the state column of the Conditional Tags pod. After you have made selections, the following can appears in the State column:

State + asterisk

What happens when you click Apply?

Gets applied to the selected text

Gets removed from the selected text

No change

Planning conditional documents

When planning a conditional document, assess the nature of the material and the number of people maintaining the document. Plan to treat conditional material consistently to make the document easier to use and maintain. Inform others of the conventions you followed as you applied condition tags.

Use these guidelines when planning a conditional tags project:

Number of versions
Define how many versions you intend the finished project to contain. For example, to create a manual that describes a program that runs on two platforms, you likely produce at least two versions. Sometimes you want these versions with editorial comments added to text during review. In this case, you can add more versions: UNIX with comments, UNIX without comments, Windows with comments, and Windows without comments.

Number of condition tags required
Decide how many condition tags you want to produce the desired versions. A unique set of condition tags defines each version of a document. For example, a Windows condition tag showing, a UNIX condition tag hidden, and a Comments condition tag hidden defines a version of a finished Windows manual. In this example, decide whether to use one condition tag for Windows comments and another for UNIX comments. You can also use a single condition tag for both Windows and UNIX comments.

Organization of content
Assess how much of the document can be conditional and how you can organize the material to simplify development and maintenance. Perhaps you can organize a book so that conditional tags is limited to a few documents. You can keep versions of a chapter in separate files rather than in conditional tags. Then use a different book file for each version of the book. Alternatively, in a structured document, you sometimes want to specify entire chapters of a book for printing only.

If a document contains graphics imported by reference into a conditional anchored frame, create separate folders for the graphics in each version. Creating separate folders simplifies file management when you copy or archive a version of the document with its graphics files.

Words and phrases that are used repeatedly in a document are easier to work with as variables than as conditional tags.

Decide whether your conditional documents need different variable definitions for each version. For example, a data sheet can use a variable with the product name, while the conditional document describes two products. You can create a template for each version of the document. Each template has only one version visible and defines the variables for that version. You can use File > Import > Formats to switch the variable definitions from one version to another.

Tagging strategy
Determine the smallest unit of conditional text. For example, if a conditional document is translated to another language, a whole sentence is the smallest amount of text you make conditional. Because word order often changes during translation, using conditional tags for part of a sentence complicates translation. Other strategies include these guidelines:
  • Decide whether to make spaces and punctuation conditional. If a conditional tag begins or ends with punctuation, make the punctuation conditional. Conditional punctuation makes the text easier to read when you’re viewing more than one version.

  • To avoid word spacing problems, set standards for handling spaces following conditional tags. Define them as either always conditional or always unconditional.

  • Decide the order in which conditional tags appear and use this order throughout the document. The order can Help subsequent authors maintain the document.

Multiple authors
If a conditional document has several authors, follow these guidelines:
  • Plan document organization and workflow. For example, break a document into small files so several people can work on different parts of the document at the same time.

  • Decide how to provide explanatory notes to other authors. To Help explain a conditional document, add helpful comments and apply the predefined Comment condition tag to them.