Basic Usage
Multi-text replacements let you define multiple text replacements in a single rule. Use this when you need to replace many texts at once.
Create a multi-text replacement rule:
- Select Custom from the toolbox
- Choose Text Replacements as the rule type
- Enter replacements using the format:
Each replacement should be on its own line.Old text = New text Another text = Replacement text Welcome = Hello
Format: Original text = Replacement text
Remove Text
To remove text entirely, leave the replacement empty:
Annoying banner =
Unwanted text =
This replaces the original text with an empty string, effectively removing it from the page.
Text Variables
Variables let you centralize replacement values. Define a variable once, then reference it in multiple multi-text replacements.
Step 1: Create a basic text rule with a variable name
- Create a Replace Text rule
- Set the Default Text to a variable name like
$CUSTOMER_NAME(must start with$and use uppercase letters, numbers, and underscores) - Set the Replacement to your default value (e.g., “Acme Corp”)
Step 2: Reference the variable in multi-text replacements In your Custom > Text Replacements rule, use the variable as the replacement:
Company Name = $CUSTOMER_NAME
Welcome to Company Name = Welcome to $CUSTOMER_NAME
Your Company = $CUSTOMER_NAME
All three replacements will use the value from your $CUSTOMER_NAME rule.
Step 3: Override the variable value To change the value for a specific demo, edit the basic Replace Text rule and update the replacement. All multi-text replacements referencing that variable will automatically use the new value.
Variable Rules
- Variable names must match
$[A-Z0-9_]+(start with$, followed by uppercase letters, numbers, or underscores) - Examples:
$CUSTOMER_NAME,$INDUSTRY,$PRODUCT_NAME,$USER_ID - Variables are case-sensitive:
$CUSTOMERand$customerare different - If a variable’s replacement is empty, multi-text rules referencing it won’t apply
- Variables must be defined in basic Replace Text rules before being used in multi-text replacements
Advanced Examples
Centralized branding:
Basic rule: $COMPANY = "Acme Corp"
Basic rule: $TAGLINE = "Innovation Delivered"
Multi-text rule:
Our Company = $COMPANY
Company Name = $COMPANY
About $COMPANY = About $COMPANY
Tagline = $TAGLINE
Dynamic personalization:
Basic rule: $CUSTOMER = "TechStart Inc"
Basic rule: $INDUSTRY = "Healthcare"
Multi-text rule:
Your Company = $CUSTOMER
Industry Leader = $INDUSTRY Leader
Built for $CUSTOMER = Built for $CUSTOMER
Conditional replacements: Create multiple multi-text rules with different URL filters, each referencing the same variable. Change the variable value to update all matching pages at once.
How It Works
Multi-text replacements are processed after basic text rules. When a variable is referenced:
- The system looks up the variable name in your basic text rules
- If found, it uses that rule’s replacement value
- If the variable’s replacement is empty, the multi-text rule is skipped
- If the variable doesn’t exist, the literal variable name is used as the replacement
Tips
- Use variables for values that appear multiple times across different texts
- Combine variables with URL filters to create page-specific customizations
- Test variable references by checking if replacements appear when demo mode is enabled
- Keep variable names descriptive and consistent across your rules
- Use empty replacements to remove unwanted text without affecting layout