Skip to main content

Macro Functions

Introduction​

With the button functions or f(x) you can perform some operations in your conditions and templates.

Conditions Templates

There are some rules to have into account when using these functions:

  • Functions will be surrounded by [MACRO][#MACRO] tag.

    [MACRO]base64_encode(Lorem ipsum)[#MACRO]
    // TG9yZW0gaXBzdW0=
  • Parameters in these functions will be passed using | as separator and leaving no spaces before or after them.

    [MACRO]sum(1|2|3)[#MACRO]
    // 6
  • Quotes " and ' are not needed to pass string parameters.

    [MACRO]htmlspecialchars(Lorem & ipsum)[#MACRO]
    // Lorem & ipsum
  • If a space is between the parameters separator | | it will be taken as a string parameter.

    [MACRO]str_replace(_| |Lorem_ipsum_dolor)[#MACRO]
    // Lorem ipsum dolor

Let’s see a brief description and an example of every function you have available in this section:

Strings​

Is array​

Checks if the value passed as parameter is an array.

[MACRO]is_array(value)[#MACRO]
[MACRO]is_array(asdf)[#MACRO]
// 0

Is bool​

Checks if the value passed as parameter is a boolean.

[MACRO]is_bool(value)[#MACRO]
[MACRO]is_bool(true)[#MACRO]
// 1

Is numeric​

Checks if the value passed as parameter is a number.

[MACRO]is_numeric(value)[#MACRO]
[MACRO]is_numeric(5)[#MACRO]
// 1

Is object​

Checks if the value passed as parameter is a object.

[MACRO]is_object(value)[#MACRO]
[MACRO]is_object(array('test'))[#MACRO]
// true

Is string​

Checks if the value passed as parameter is a string.

[MACRO]is_string(value)[#MACRO]
[MACRO]is_string(This is a text)[#MACRO]
// 1

Lowercase first​

Makes a string’s first character lowercase.

[MACRO]lcfirst(string)[#MACRO]
[MACRO]lcfirst(Text)[#MACRO]
// text

[MACRO]lcfirst(TEXT)[#MACRO]
// tEXT

Levenshtein​

Calculates Levenshtein distance between two strings.

[MACRO]levenshtein(string|string2)[#MACRO]
[MACRO]levenshtein(Hello World|llo World)[#MACRO]
// 2

[MACRO]levenshtein(Hello World|llo)[#MACRO]
// 8

Left trim​

Strips whitespaces (or other characters) from the beginning of a string.

[MACRO]ltrim(string|character_mask)[#MACRO]
[MACRO]ltrim(    Lorem ipsum dolor sit amet)[#MACRO]
// Lorem ipsum dolor sit amet

[MACRO]ltrim(---Lorem ipsum dolor sit amet|-)[#MACRO]
// Lorem ipsum dolor sit amet

[MACRO]ltrim(-_-_Lorem ipsum dolor sit amet|_-)[#MACRO]
// Lorem ipsum dolor sit amet

We’ve inserted some spaces on the left in the first example.

Preg replace​

Searchs with regular expression and replaces.

[MACRO]preg_replace(pattern|replacement|string)[#MACRO]
[MACRO]preg_replace(/london/i|New York|visit London)[#MACRO]
// visit New York

Remove break lines​

Merges the text passed as parameter in one line.

[MACRO]remove_break_lines(string)[#MACRO]
[MACRO]remove_break_lines(
lorem
ipsum
dolor)[#MACRO]
// loremipsumdolor

Right trim​

Strips whitespaces (or other characters) from the end of a string.

[MACRO]rtrim(string|character_mask)[#MACRO]
[MACRO]rtrim(Lorem ipsum dolor sit amet    )[#MACRO]
// Lorem ipsum dolor sit amet

[MACRO]rtrim(Lorem ipsum dolor sit amet---|-)[#MACRO]
// Lorem ipsum dolor sit amet

[MACRO]rtrim(Lorem ipsum dolor sit amet-_-_|_-)[#MACRO]
// Lorem ipsum dolor sit amet

We’ve inserted some spaces at right in the first example.

Similar text​

Calculates the similarity between two strings.

[MACRO]similar_text(string|string2)[#MACRO]
[MACRO]similar_text(lorem|lorem)[#MACRO]
// 100

[MACRO]similar_text(lorem|ipsum)[#MACRO]
// 20

Random​

Generates random values.

[MACRO]special_random(chars_list|length|type)[#MACRO]
[MACRO]special_random(red#sun|9|LIST)[#MACRO]
// sunsunred

[MACRO]special_random(|5|ALL)[#MACRO]
// 6qA5*

[MACRO]special_random(|15|NUMBERS)[#MACRO]
// 618774390883773

[MACRO]special_random(abc|10|CUSTOM)[#MACRO]
// baabbcbaab

note

The first argument is only taken into account when the third one is "CUSTOM". It randomizes using the first argument's characters.

String pad​

Pads a string to a certain length with another string.

[MACRO]str_pad(string|pad_length|pad_string|pad_type)[#MACRO]
[MACRO]str_pad(Text|10)[#MACRO]
// Text

[MACRO]str_pad(Text|10|-=|STR_PAD_LEFT)[#MACRO]
// -=-=-=Text

[MACRO]str_pad(Text|10|_|STR_PAD_BOTH)[#MACRO]
// ___Text___

Notice that first output comes with spaces at right.

String repeat​

Repeats a string.

[MACRO]str_repeat(string|multiplier)[#MACRO]
[MACRO]str_repeat(Text|3)[#MACRO]
// TextTextText

String replace​

Replaces all occurrences of the search string with the replacement string.

[MACRO]str_replace(search|replace|string)[#MACRO]
[MACRO]str_replace(-|_|lorem-ipsum-dolor)[#MACRO]
// lorem_ipsum_dolor

String shuffle​

Randomly shuffles a string.

[MACRO]str_shuffle(string)[#MACRO]
[MACRO]str_shuffle(lorem ipsum dolor)[#MACRO]
// d romlisrpomou el

String to object​

Converts a string to a object.

[MACRO]str_to_object(value)[#MACRO]
[MACRO]str_to_object({"Peter":35,"Ben":37,"Joe":43})[#MACRO]
// {"Peter":35,"Ben":37,"Joe":43}

String case-insensitive position​

Finds the position of the first occurrence of a case-insensitive substring in a string.

[MACRO]stripos(string|needle|offset)[#MACRO]
[MACRO]stripos(aba ABA aba|b)[#MACRO]
// 1

[MACRO]stripos(aba ABA aba|b|3)[#MACRO]
// 5

String length​

Returns the length of the given string.

[MACRO]strlen(string)[#MACRO]
[MACRO]strlen("adsf sdf")[#MACRO]
// 10

[MACRO]strlen(lorem ipsum...)[#MACRO]
// 14

String position​

Finds the position of the first occurrence of a substring in a string.

[MACRO]strpos(string|needle|offset)[#MACRO]
[MACRO]strpos(aba ABA aba|b)[#MACRO]
// 1

[MACRO]strpos(aba ABA aba|b|3)[#MACRO]
// 9

String to lower​

Makes a string lowercase.

[MACRO]strtolower(string)[#MACRO]
[MACRO]strtolower(TEXT)[#MACRO]
// text

String to upper​

Makes a string uppercase.

[MACRO]strtoupper(string)[#MACRO]
[MACRO]strtoupper(text)[#MACRO]
// TEXT

String contains​

Determine if a string contains a given substring

[MACRO]str_contains(string|needle)[#MACRO]
[MACRO]str_contains(Lorem ipsum dolor sit amet|sit )[#MACRO]
// true

String starts with​

Checks if a string starts with a given substring

[MACRO]str_starts_with(string|needle)[#MACRO]
[MACRO]str_starts_with(Lorem ipsum dolor sit amet|Lorem)[#MACRO]
// true

String ends with​

Checks if a string ends with a given substring

[MACRO]str_ends_with(string|needle)[#MACRO]
[MACRO]str_ends_with(Lorem ipsum dolor sit amet|amet)[#MACRO]
// true

Substring​

Returns part of a string.

[MACRO]substr(string|start|length)[#MACRO]
[MACRO]substr(lorem ipsum dolor|6|5)[#MACRO]
// ipsum

[MACRO]substr(lorem ipsum dolor|-8)[#MACRO]
// um dolor

[MACRO]substr(lorem ipsum dolor|2)[#MACRO]
// rem ipsum dolor

Trim​

Strips whitespaces (or other characters) from the beginning and end of a string.

[MACRO]trim(string|character_mask)[#MACRO]
[MACRO]trim(   Lorem ipsum dolor sit amet   )[#MACRO]
// Lorem ipsum dolor sit amet

[MACRO]trim(---Lorem ipsum dolor sit amet___|-_)[#MACRO]
// Lorem ipsum dolor sit amet

We’ve inserted some spaces on the right and left in the first example.

Uppercase first​

Makes a string’s first character uppercase.

[MACRO]ucfirst(string)[#MACRO]
[MACRO]ucfirst(text)[#MACRO]
// Text

Uppercase words​

Convert the first character of each word in a string to uppercase.

Parameters​

string: This is the text string that you want to convert. Each word in the string will have its first letter converted to uppercase.

delimiters: This is an optional parameter. It is a list of one or more characters that specifies the points where the string will be split into words.

[MACRO]ucwords(string|delimiters)[#MACRO]
[MACRO]ucwords(lorem ipsum dolor| )[#MACRO]
// Lorem Ipsum Dolor
[MACRO]ucwords(lorem-ipsum-dolor|-)[#MACRO]
// Lorem-Ipsum-Dolor

The second parameter of the first function is a space character, and for the second function, it is a hyphen character.

Strip_tags​

Strip_tags() is a function that allows you to strip out all HTML tags from a given string.

[MACRO]strip_tags(string)[#MACRO]
[MACRO]strip_tags(<p>Lorem ipsum dolor</p>)[#MACRO]
// Lorem ipsum dolor

Date​

Date​

Formats a local time/date. Visit this link for a complete guide of the supported characters for the format.

[MACRO]date(datetime|timestamp)[#MACRO]
[MACRO]date(Y-m-d H:i:s)[#MACRO]
// 2020-10-08 16:57:46

[MACRO]date(j M Y)[#MACRO]
// 8 Oct 2020

Date add​

Adds an amount of days, months, years, hours, minutes and seconds to a DateTime object. More information in this link.

[MACRO]date_add(datetime|interval|format|timezone)[#MACRO]
[MACRO]date_add(01-01-2000|P10D|d-m-Y)[#MACRO] // Adding 10 days
// 11-01-2000

[MACRO]date_add(01-01-2000|P1M|d-m-Y)[#MACRO] // Adding 1 month
// 01-02-2000

[MACRO]date_add(01-01-2000 00:00:00|PT1S|d-m-Y H:i:s|Europe/Amsterdam)[#MACRO] // Adding 1 second
// 01-01-2000 00:00:01

[MACRO]date_add(01-01-2000 00:00:00|PT6H|d-m-Y H:i:s|Europe/Amsterdam)[#MACRO] // Adding 6 hours
// 01-01-2000 06:00:00

Date diff​

Returns the difference between two DateTime objects.

[MACRO]date_diff(datetime1|datetime2|format)[#MACRO]
[MACRO]date_diff(11-01-2000|01-02-2000|%R%a days)[#MACRO]
// +21 days

Date format​

Outputs a datetime with a given format. Visit this link for a complete guide of the supported characterss for the format.

[MACRO]date_format(datetime|format|timezone)[#MACRO]
[MACRO]date_format("2018-06-02 12:00:00"|"Y-m-d"|"Europe/London")[#MACRO]
// 2018-06-02

[MACRO]date_format(@system.date.universal_datetime@|"d M Y H:i"|"Europe/London")[#MACRO]
// 07 Jun 2018 16:05

Date format with language​

Outputs a datetime with a given format in a specific language. Find here the characters supported for the input format and here the strings supported for the output.

[MACRO]date_format_lang(datetime|format|timezone|lang|out_format|out_timezone)[#MACRO]
[MACRO]date_format_lang(@system.date.universal_datetime@|"Y-m-d H:i:s"|"Europe/London"|"en_us"|"MMMM dd, y HH:mm:ss"|"America/Chicago")[#MACRO]
// June 07, 2018 11:08:07

Date sub​

Subtract an amount of days, months, years, hours, minutes and seconds from a DateTime object.

[MACRO]date_sub(datetime|interval|format|timezone)[#MACRO]
[MACRO]date_sub(11-01-2000|P10D|d-m-Y)[#MACRO] // Subtracting 10 days
// 01-01-2000

[MACRO]date_sub(01-03-2000|P1M|d-m-Y)[#MACRO] //Subtracting 1 month
// 01-02-2000

Date to timestamp​

Converts a specified date into a timestamp.

[MACRO]date_to_timestamp(date|unicode_format|lang|timezone)[#MACRO]
[MACRO]date_to_timestamp(Dinsdag 12 augustus 2019|EEEE dd MMMM yyyy|nl_nl|Europe/Madrid)[#MACRO]
// 1565560800

[MACRO]date(Y-m-d H:i:s| 1565560800)[#MACRO]
// 2019-08-12 00:00:00
[MACRO]date_to_timestamp(date|unicode_format|lang|timezone)[#MACRO]
[MACRO]date_to_timestamp(Dinsdag 12 augustus 2019|EEEE dd MMMM yyyy|nl_nl|Europe/Madrid)[#MACRO]
// 1565560800

[MACRO]date_format_lang(1565560800|U|Europe/Amsterdam|es_es|d MMMM y|Europe/Madrid)[#MACRO]
// 12 agosto 2019

Standard ISO date and time format specifiers​

Format CharacterDescriptionExample Returned Values
Day
dDay of the month, 2 digits with leading zeros01 to 31
DA textual representation of a day, three letters (always in English)Mon through Sun
jDay of the month without leading zeros1 to 31
lA full textual representation of the day of the week (always in English)Sunday through Saturday
NISO-8601 numeric representation of the day of the week1 (for Monday) through 7 (for Sunday)
SEnglish ordinal suffix for the day of the month, 2 charactersst, nd, rd or th. Works well with j
wNumeric representation of the day of the week0 (for Sunday) through 6 (for Saturday)
zThe day of the year (starting from 0)0 through 365
Week
WISO-8601 week number of year, weeks starting on MondayExample: 42 (the 42nd week in the year)
Month
FA full textual representation of a month, such as January or March (always in English)January through December
mNumeric representation of a month, with leading zeros01 through 12
MA short textual representation of a month, three letters (always in English)Jan through Dec
nNumeric representation of a month, without leading zeros1 through 12
tNumber of days in the given month28 through 31
Year
LWhether it's a leap year1 if it is a leap year, 0 otherwise.
oISO-8601 week-numbering year. This has the same value as Y, except that if the ISO week number (W) belongs to the previous or next year, that year is used instead.Examples: 1999 or 2003
YA full numeric representation of a year, 4 digitsExamples: 1999 or 2003
yA two digit representation of a yearExamples: 99 or 03
Time
aLowercase Ante meridiem and Post meridiemam or pm
AUppercase Ante meridiem and Post meridiemAM or PM
BSwatch Internet time000 through 999
g12-hour format of an hour without leading zeros1 through 12
G24-hour format of an hour without leading zeros0 through 23
h12-hour format of an hour with leading zeros01 through 12
H24-hour format of an hour with leading zeros00 through 23
iMinutes with leading zeros00 to 59
sSeconds, with leading zeros00 through 59
uMicrosecondsExample: 654321
Timezone
eTimezone identifierExamples: UTC, GMT, Atlantic/Azores
I (capital i)Whether or not the date is in daylight saving time1 if Daylight Saving Time, 0 otherwise.
ODifference to Greenwich time (GMT) in hoursExample: +0200
PDifference to Greenwich time (GMT) with colon between hours and minutesExample: +02:00
TTimezone abbreviationExamples: EST, MDT ...
ZTimezone offset in seconds. The offset for timezones west of UTC is always negative, and for those east of UTC is always positive.-43200 through 50400
Full Date/Time
cISO 8601 date2004-02-12T15:19:21+00:00
rΒ» RFC 2822 formatted dateExample: Thu, 21 Dec 2000 16:01:07 +0200
USeconds since the Unix Epoch (January 1 1970 00:00:00 GMT)1335939007

Math​

Division​

Divides all values passed as parameters.

[MACRO]division(number|number2|number3...)[#MACRO]
[MACRO]division(100|50|60)[#MACRO]
// 0.033333333333333

Eval spreadsheet formula​

Evaluates a spreadsheet formula.

[MACRO]eval_spreadsheet_formula(string)[#MACRO]
[MACRO]eval_spreadsheet_formula(SUM(1,2))[#MACRO]
// 3

Use english function names, . as decimal separator, , as function argument separator and ; as matrix row separator.

Hexadecimal to binary​

Decodes a hexadecimally encoded binary string.

[MACRO]hex2bin(number)[#MACRO]
[MACRO]hex2bin(6578616d706c65206865782064617461)[#MACRO]
// example hex data

Multiply​

Multiplies all values passed as parameters.

[MACRO]multiply(number|number2|number3...)[#MACRO]
[MACRO]multiply(100|50|60)[#MACRO]
// 300000

Number format​

Formats a number with grouped thousands.

[MACRO]number_format(number|decimals|dec_point|thousands_sep)[#MACRO]
[MACRO]number_format(1234.5687|2|,|.)[#MACRO]
// 1.234,57

Opposite​

Calculates the positive value if the param is negative and inverse.

[MACRO]opposite(number)[#MACRO]
[MACRO]opposite(-5)[#MACRO]
// 5

Round​

Rounds a number.

[MACRO]round(number|precision)[#MACRO]
[MACRO]round(15.727845677|3)[#MACRO]
// 15.728

Random​

Generates random values.

[MACRO]special_random(length|type)[#MACRO]
[MACRO]special_random(red#sun|9|LIST)[#MACRO]
// redredredredsunredredsunred

[MACRO]special_random(|5|ALL)[#MACRO]
// 6qA5*

[MACRO]special_random(|15|NUMBERS)[#MACRO]
// 618774390883773

[MACRO]special_random(abc|10|CUSTOM)[#MACRO]
// baabbcbaab

Subtract​

Subtracts all numbers passed as parameters.

[MACRO]subtract(number|number2|number3...)[#MACRO]
[MACRO]subtract(100|50|60)[#MACRO]
// -10

Sum​

Sums all numbers passed as parameters.

[MACRO]sum(number|number2|number3...)[#MACRO]
[MACRO]sum(100|50|60)[#MACRO]
// 210

Encoding​

Base64 decode​

Decodes a MIME base64 encoded data.

[MACRO]base64_decode(string)[#MACRO]
[MACRO]base64_decode(bXljb2Rl)[#MACRO]
// mycode

Base64 encode​

Encodes the given data with MIME base64.

[MACRO]base64_encode(string)[#MACRO]
[MACRO]base64_encode(mycode)[#MACRO]
// bXljb2Rl

Get public URL​

Outputs a URL to access a file from the file manager.

[MACRO]get_public_url(string|custom_domain)[#MACRO]
[MACRO]get_public_url(path/to/file.txt)[#MACRO]
// https://demo.flowize.com/assets/flushfile/file.txt?uri=n8mJsBYXP68K3LguY9Krs0c2VdpKw

[MACRO]get_public_url(path/to/file.txt|https://flow.mycompany.com)[#MACRO]
// https://flow.mycompany.com/assets/flushfile/file.txt?uri=n8mJsBYXP68K3LguY9Krs0c2VdpKw

JSON decode​

Takes a JSON encoded string and converts it into a PHP variable.

[MACRO]json_decode(string)[#MACRO]
[MACRO]json_decode({"a":1,"b":2,"c":3})[#MACRO]
// object(stdClass)[1]
// public 'a' => int 1
// public 'b' => int 2
// public 'c' => int 3

JSON encode​

Returns a string containing the JSON representation of value. This function will process non-associative and associative arrays but not multidimensional ones.

[MACRO]json_encode(value|flag)[#MACRO]
[MACRO]json_encode(array('a' => 1, 'b' => 2, 'c' => 3))[#MACRO]
// {"a":1,"b":2,"c":3}

The output actually is a PHP variable so we’ve run var_dump() to have a represntation of it.

JSON to XML​

Converts a JSON structure into an XML structure.

[MACRO]json_xml(string)[#MACRO]
[MACRO]json_xml({'name':'My Widget','widget':{'window':{'width':500,'height':500},'image':{'src':'Images/Sun.png','name':'sun1'},'text':'data':'Click Here','size':36}}})[#MACRO]
// <?xml version="1.0" encoding="UTF-8"?>
//<root>
// <name>My Widget</name>
// <widget>
// <window>
// <width>500</width>
// <height>500</height>
// </window>
// <image>
// <src>Images/Sun.png</src>
// <name>sun1</name>
// </image>
// <text>
// <data>Click Here</data>
// <size>36</size>
// </text>
// </widget>
//</root>

Mb convert encoding​

Convert character encoding

[MACRO]mb_convert_encoding(string|to_encoding|from_encoding)[#MACRO]
[MACRO]mb_convert_encoding(mΓΊsica|UTF-7)[#MACRO]
// m+APo-sica

XML to JSON​

Converts an XML structure into a JSON structure.

[MACRO]xml_json(string)[#MACRO]
[MACRO]xml_json(
<?xml version="1.0" encoding="UTF-8"?>
<root>
<name>My Widget</name>
<widget>
<window>
<width>500</width>
<height>500</height>
</window>
<image>
<src>Images/Sun.png</src>
<name>sun1</name>
</image>
<text>
<data>Click Here</data>
<size>36</size>
</text>
</widget>
</root>
)[#MACRO]

// {
// "name":"My Widget",
// "widget":{
// "window":{
// "width":"500",
// "height":"500"
// },
// "image":{
// "src":"Images/Sun.png",
// "name":"sun1"
// },
// "text":{
// "data":"Click Here",
// "size":"36"
// }
// }
// }

HTML​

Decode entities​

Converts all HTML entities to their applicable characters.

[MACRO]html_entity_decode(string)[#MACRO]
[MACRO]html_entity_decode(&lt;b&gt;Bold text&lt;/b&gt;)[#MACRO]
// <b>Bold text</b>

Encode entities​

Converts all applicable characters to HTML entities.

[MACRO]htmlentities(string)[#MACRO]
[MACRO]htmlentities(<b>Bold text</b>)[#MACRO]
// &lt;b&gt;Bold text&lt;/b&gt;

Specialchars​

Converts special characters to HTML entities.

[MACRO]htmlspecialchars(string)[#MACRO]
[MACRO]htmlspecialchars(Ampersands & double quote " less < and grater > than)[#MACRO]
// Ampersands &amp; double quote &quot; less &lt; and grater &gt; than

Specialchars decode​

Converts special HTML entities back to characters.

[MACRO]htmlspecialchars_decode(string)[#MACRO]
[MACRO]htmlspecialchars_decode(Ampersands &amp; double quote &quot; less &lt; and grater &gt; than)[#MACRO]
// Ampersands & double quote " less < and grater > than

nl to br​

Inserts HTML line breaks before all newlines in a string.

[MACRO]nl2br(string)[#MACRO]
[MACRO]nl2br(This
string
in
lines)[#MACRO]
// This<br>
// string<br>
// in<br>
// lines

URL decode​

Decodes URL-encoded string (decodes any %## encoding in the given string, plus symbols β€œ+” are decoded to a space character).

[MACRO]urldecode(string)[#MACRO]
[MACRO]urldecode(http%3A%2F%2Fdomain.com%2Fdir%3Fa%3Dsome+text%26b%3Dother)[#MACRO]
// http://domain.com/dir?a=some text&b=other

URL encode​

URL-encodes strings, useful when encoding a string to be used in a query part of a URL, as a convenient way to pass variables to the next page.

[MACRO]urlencode(string)[#MACRO]
[MACRO]urlencode(http://domain.com/dir?a=some text&b=other)[#MACRO]
// http%3A%2F%2Fdomain.com%2Fdir%3Fa%3Dsome+text%26b%3Dother

Encrypting​

crc32​

Calculates the crc32 polynomial of a string.

[MACRO]crc32(string)[#MACRO]
[MACRO]crc32(Lorem ipsum dolor)[#MACRO]
// 1317584614

Crypt​

One-way string hashing.

[MACRO]crypt(string|salt)[#MACRO]
[MACRO]crypt(Lorem ipsum dolor|a6dhgf67)[#MACRO]
// $2y$12$Au8efpLLlx6cxGQYEq09heruPW59zVclFNwxe.QQfQ3ov9.xJYNZ6

Hash hmac​

Hash value using the HMAC method

[MACRO]hash_hmac(string|algorithm|message|key|raw_output)[#MACRO]
[MACRO]hash_hmac(ripemd160|The quick brown fox jumped over the lazy dog|secret)[#MACRO]
// 9880cc6f27e5510f1e0dcb95f47074f9ade83106

MD5​

Calculates the md5 hash of a string.

[MACRO]md5(string)[#MACRO]
[MACRO]md5(Lorem ipsum dolor)[#MACRO]
// 06ce95ac476fc656cea3fca5d02cfd81

Sha1​

Calculates the sha1 hash of a string.

[MACRO]sha1(string)[#MACRO]
[MACRO]sha1(Lorem ipsum dolor)[#MACRO]
// 45f75b844bu4d17b3894c6701768daf39419c99b

Compressing​

Inflate​

This function inflates a deflated string.

[MACRO]inflate()[#MACRO]
[MACRO]inflate(88kvSs1VyCwoLs1VSMnPyS8CAA==)[#MACRO]
// Lorem ipsum dolor

Deflate​

This function compresses the given string using the DEFLATE data format. The level of compression. Can be given as 0 for no compression up to 9 for maximum compression.

[MACRO]deflate(string|level)[#MACRO]
[MACRO]deflate(Lorem ipsum dolor|6)[#MACRO]
// 88kvSs1VyCwoLs1VSMnPyS8CAA==

Compress​

This function compresses the given string using the ZLIB data format. The level of compression. Can be given as 0 for no compression up to 9 for maximum compression.

[MACRO]compress(string|level)[#MACRO]
[MACRO]compress(Lorem ipsum dolor|6)[#MACRO]
// eJzzyS9KzVXILCguzVVIyc/JLwIAOd8Gjg==

Uncompress​

This function uncompress a compressed string.

[MACRO]uncompress()[#MACRO]
[MACRO]uncompress(eJzzyS9KzVXILCguzVVIyc/JLwIAOd8Gjg==)[#MACRO]
// Lorem ipsum dolor