When customizing a Blogger template, one of the most overlooked but powerful tools is the concatenation operator [+]. If you are familiar with programming languages such as PHP or JavaScript, you have probably seen this operator used to join strings together. Blogger templates also support a similar feature, allowing you to combine text, data, and expressions into a single string value.
In this expanded tutorial, we will explore what the concatenation operator does in Blogger, how it differs from the mathematical plus symbol, and practical ways to apply it in your blog’s template. This guide will cover syntax variations, functional approaches, and several real-world examples. By the end, you’ll understand how to merge strings, add dynamic data from your blog, and create cleaner template code.
What is the Concatenation Operator [+]?
In Blogger templates, the plus sign (+) does not act as a mathematical addition operator. Instead, it is used as a string concatenation operator. This means it joins two or more pieces of text (or values) into one continuous string.
For example, combining the strings "I love" and " Blogger" using the operator will produce I love Blogger. The operator is especially useful when you want to mix static text with dynamic values such as your blog’s title, post titles, or even conditional expressions.
Concatenation Syntax in Blogger
The concatenation operator can be applied in two primary ways within Blogger templates. Both methods ultimately return a string.
Syntax 1
{string} + {allType}
This means a string is combined with another value (which can be any type), resulting in a string output.
Syntax 2
{allType} + {string}
This means any type of value is combined with a string, also resulting in a string output.
- The
+operator acts as a bridge between string characters and values of different types. - Do not confuse this operator with the mathematical addition operator. Here, the purpose is joining, not adding.
- Operands can be:
- Explicit values (e.g.,
"Hello"). - Data from Blogger (e.g.,
data:blog.title). - Results of nested expressions (e.g., conditional logic).
- Explicit values (e.g.,
- You can nest multiple concatenations together for more complex results.
Examples of Using the Concatenation Operator
Let’s look at different scenarios where you might use concatenation in Blogger templates.
1. Concatenating Two Explicit Values
<b:eval expr='"I love" + " Blogger"'/>
Output: I love Blogger
2. Concatenating a String and Blog Data
<b:eval expr='"I love " + data:blog.title'/>
If your blog title is KodeRian, the output will be: I love KodeRian
3. Mixing Multiple Values and Data
<b:eval expr='"Reading " + data:blog.title + " feels " + data:blog.languageDirection + "."'/>
If the blog title is KodeRian and language direction is ltr, the output will be: Reading KodeRian feels ltr.
4. Using Nested Expressions
<b:eval expr='"Blog " + data:blog.title + " is " + (data:blog.isPrivate ? "private" : "public") + "."'/>
If the blog is public, the output will be: Blog KodeRian is public
Functional Syntax
Blogger also supports a functional syntax for concatenation. This alternative format is useful when you are combining multiple values at once. Instead of writing long chains of +, you can use parentheses to group values.
+(string, allType, allType, allType)
Example of Functional Syntax
+( "Read ", data:blog.title, " - ", data:post.title, " (", data:link.url, ")" )
Output: A combined string that includes the blog title, post title, and URL. For example:
Read KodeRian - How to Use Blogger Operators (https://yourblog.com/post-url)
Step-by-Step Tutorial: Adding Concatenation in Blogger
Here’s how you can try concatenation in your own Blogger theme:
- Log in to your Blogger Dashboard.
- Go to Theme → Edit HTML.
- Locate the section of code where you want to display combined text (for example, post headers, meta descriptions, or footer).
- Insert the
<b:eval expr=...>snippet with concatenation code. - Save the template and preview your blog to see the result.
When Should You Use Concatenation in Blogger?
Concatenation can be helpful in various situations, such as:
- Custom post titles: Add extra text or metadata next to post titles automatically.
- SEO descriptions: Combine static text with post or blog data to generate dynamic meta descriptions.
- Conditional messages: Use expressions to display text based on whether your blog is public, private, or has certain attributes.
- Custom widgets: Combine strings to create custom links, headers, or footers without hardcoding text.
Extra Tips
- Keep it clean: Don’t overuse concatenation; too many values can make the template hard to read.
- Debug carefully: If something doesn’t display, check for missing quotes or mismatched operators.
- Use functional syntax: For long concatenations, functional syntax is neater and less error-prone.
- Test in preview: Always test concatenation changes in the Blogger preview before publishing.
FAQ: Blogger Concatenation Operator [+]
1. Is this the same as JavaScript concatenation?
Yes and no. The idea is the same (joining strings), but here it works inside Blogger’s XML template system using <b:eval> expressions.
2. Can I use numbers with this operator?
Yes. When numbers are concatenated with strings, they are converted to strings automatically. Example: "Views: " + 150 becomes Views: 150.
3. Does concatenation affect SEO?
Indirectly, yes. By using concatenation, you can create dynamic titles or descriptions that help search engines understand your content better.
4. Can I mix conditional logic with concatenation?
Absolutely. Use the ternary operator (?:) inside concatenation for conditional results, as shown in the nested example above.
Troubleshooting Common Issues
1. Output Not Showing?
Make sure you wrapped the code inside <b:eval expr=...>. Blogger won’t render concatenation if you place it in plain text.
2. Broken Quotes?
Always double-check your quotation marks. Use " around strings, and escape properly if needed.
3. Unexpected Spaces?
Remember that concatenation doesn’t add spaces automatically. You must include spaces inside your strings, e.g., "Hello " + data:blog.title.
4. Too Long Expressions?
Switch to functional syntax to simplify long concatenations.
Conclusion
The Blogger concatenation operator [+] is a small but powerful feature that helps you merge text and data dynamically within your template. Whether you are combining static strings, blog metadata, or even conditional logic, mastering this operator gives you more flexibility and control over how your blog displays information.
By applying the examples and tips from this tutorial, you can make your Blogger theme more dynamic, SEO-friendly, and user-oriented.
If this tutorial helped you, be sure to bookmark it, share it with fellow bloggers, and subscribe for more Blogger customization tips!

![How to Use the Concatenation Operator [+] in Blogger Templates How to Use the Concatenation Operator [+] in Blogger Templates](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhpl9htnhl3fj-_CnPyQV8CyXD61IlCq-NO3WIIlcV29fIfcS2MySRb7YK9vJ2x9rWFmfTC0nA2kwDQwniJoKPHgxkG5TXuj4GaAMJYZJlEwVjllaiYBhHCFWUmwbR5nZmUvFh2wvW5uwc/w640-h427-rw/operator-gabungan.jpg)

Post a Comment
Please keep your comments relevant to the topic (Blogger, SEO, coding, etc.).
Be respectful — no spam, offensive language, or personal attacks.
You may share suggestions, bug reports, or tutorial requests.
External links are allowed only if they are truly helpful and not for promotion.
Feedback will be reviewed, and I will try to reply as soon as possible.
By commenting here, you help improve KodeRian and keep the discussion useful for everyone.