Overview
String tags are used to manipulate strings and output results to the content. Strings can be literal (defined with or without quotes), variable (set in the template ), or Contact or Custom Data. The tags can be used in conjunction with template logic tags.
Tags
The following tables include all String Manipulation related Tags.
Tag | %%concat RESULT STR1 STRn%% |
Alternate | %%join [RESULT] [STR1] [STRn]%% %%append [RESULT] [STR1] [STRn]%% |
Parameters | RESULT: Variable STR1 to STRn: Literal, Variable, Custom Data or Contact Data |
Output | Set the value of the result string variable to the contents of one to n number strings, including a space between each string. |
Example | %%concat spaceStr $string1 "World" $customString $email%% %%$spaceStr%% |
Results | Hello World Hello mymail@ domain.com |
Tag | %%nospace_concat RESULT STR1 STRn%% |
Alternate | %%nospace_join [RESULT] [STR1] [STRn]%% %%nospace_append [RESULT] [STR1] [STRn]%% |
Parameters | RESULT: Variable STR1 to STRn: Literal, Variable, Custom Data or Contact Data |
Output | Set the value of the result string variable to the contents of one to n number strings, with no space between each string. |
Example | %%nospace_concat nospaceStr $string1 "World" $customString $email%% %%$nospaceStr%% |
Results | HelloWorldHellomymail@ domain.com |
Tag | %%urlencode STRING%% |
Parameter | STRING: Unquoted literal, Variable, Custom Data or Contact Data |
Output | Output defined unquoted string as url encoded string. If quotes included, they will be converted as part of the string. |
Example | %%urlencode http:// domain.com?id=1&name=myname%% |
Results | http%3A%2F%2Fdomain.com%3Fid%3D1%26name%3Dmyname |
Tag | %%urldecode STRING%% |
Parameter | STRING: Unquoted literal, Variable, Custom Data or Contact Data |
Output | Output unquoted url encoded string as a decoded string. If quotes included, they will be output as part of the string. |
Example | %%urldecode http%3A%2F%2Fdomain.com%3Fid%3D1%26name%3Dmyname%% |
Results | http// domain.com?id=1&name=myname |
Tag | %%base64encode STRING%% |
Parameter | STRING: Literal, Variable, Custom Data or Contact Data |
Output | Output defined string in Base 64 encoding. |
Example | %%base64encode "Hello"%% %%base64encode $string1%% %%base64encode $customString%% |
Results | SGVsbG8= |