Logmanager documentation
Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

Text append to variable

Block appends connected string value to an existing variable value. Left side defines the variable. String value from right side is appended to string in specified variable.

Block XML representation

XML representation of text_append block:

<xml xmlns="http://www.w3.org/1999/xhtml">
  <block type="text_append">
    <field name="VAR">item</field>
    <value name="TEXT">
      <block type="text">
        <field name="TEXT">value</field>
      </block>
    </value>
  </block>
</xml>

Example of visual representation

Block "Append some text to variable"

Block “Append some text to variable”

Example of block usage

Example of "Append some text to variable" block

Example of “Append some text to variable” block

Block is used with variables “join_text” and “join_item” in the example.

Variable “join_text”:

  1. Appends text “address” to the variable, output is value “ipaddress”.
  2. Appends value of the “join_text” variable (text: “ipaddress”) to the variable, output is value “ipaddressipaddress”.
  3. Appends value of the “user” key from “item” dictionary to the variable (text: “administrator”), output value is “ipaddressipaddressadministrator”.

Cycle is used to go through the “item” dictionary values and a text containing all keys and values of “item” dictionary is saved to the “join_item” variable:

  1. The value of variable “key” is appended to the variable (value “user”).
  2. The colon character is appended to the variable.
  3. The value of the key “key” from the “item” dictionary is appended to the variable (value “administrator”).
  4. The semicolon character is appended to the variable.
  5. The value of variable “key” is appended to the variable (value “ip”).
  6. The colon character is appended to the variable.
  7. The value of the key “key” from the “item” dictionary is appended to the variable (value “8.8.8.8”).
  8. The semicolon character is appended to the variable.

Processing result

Results of "Append some text to variable" block

Results of “Append some text to variable” block