Function |
Description |
---|---|
Decodes a string from a Base64 representation |
|
Encodes a string into a Base64 representation |
|
Converts a date string into the default or a custom date format |
|
Converts Hexadecimal value into Integer value |
|
Converts Integer value into hexadecimal digits |
|
Composes a string from hexadecimal values |
|
Encodes the characters of a string into hexadecimal notation |
|
Converts a string into its Unicode representation |
|
Decodes a string replacing the escape sequences with their original values |
|
Replaces certain characters in an URI with escape sequences |
Decodes a string from a Base64 representation
string uBase64Decode(input)
The string to decode
uBase64Decode("QSBzZWNyZXQ=") // returns "A secret"
Encodes a string into a Base64 representation
string uBase64Encode(input)
The string to encode.
uBase64Encode("A secret") // returns "QSBzZWNyZXQ="
Converts
a date string into the default or a custom date format. The first parameter
is the date string to be converted; the second parameter is a format string,
specifying the date format of the input date string (see the following table).
The outputformat parameter is optional, and
if it is omitted, the date is converted in the format y-M-D
H:N:S
.
The function handles dates from 1582 to present day. If the date cannot be converted, the result string will be empty.
string uConvertDate(datestring, inputformat [, outputformat])
The date string to convert
The date/time format of the input string
The desired output format. If omitted, the default
format is y-M-D H:N:S
.
Convert date strings into a different formats
uConvertDate("2005-06-27 00:00:00","y-M-D H:N:S","D mY") // returns "27 JUN 05"
uConvertDate("27 JUN 05", "D m Y") // returns "2005-06-27 00:00:00"
The function uConvertDate converts a date
string into a different format using a source and a destination
format string. The first parameter is the date string to be converted.
The second parameter is a format string, specifying the date format
of the input date (see list below). The outputformat parameter is optional.
If omitted the date will be converted using the format y-M-D
H:N:S
. The function handles dates from 1582 to
present day. If the date could not be converted, the result string
will be empty.
Identifier |
Description |
---|---|
Y |
year 2-digits (06) |
y |
year 4-digits (2006) |
|
century (20) |
|
month (03) |
|
month (JUN) |
|
day (12) |
|
hour (00..23) |
|
hour (01..12) |
|
minutes |
|
seconds |
|
hundredth of seconds |
|
thousandth of seconds |
|
AM/PM |
|
day of week (5) |
|
day of week (Friday) |
|
day of year (001..366) |
|
week of year (01..52) |
|
week of month (1..6) |
Converts Hexadecimal value into Integer value
integer uFromHex(input)
The string to convert
uFromHex("A3F") // returns 2623
uFromHex("B") // returns 11
Converts Integer value into hexadecimal digits
string uToHex(input)
The integer value to convert
uToHex(45) // returns "2D"
Composes a string from hexadecimal values
string uHexDecode(input)
The hexadecimal string containing the hexadecimal values
Convert a hex value to a string
uHexDecode("313730") // returns "170"
uHexDecode(313730) // returns "170"
Encodes the characters of a string into hexadecimal notation
string uHexEncode(input)
The string to encode
Convert a string to hex values
uHexEncode("170") // returns "313730"
uHexEncode(170) // returns "313730"
Converts a string into its Unicode representation
string uToUnicode(input)
The input string
Decodes a string replacing the escape sequences with their original values
string uURIDecode(uri)
The URI to decode
uURIDecode(“..www.myServer.com/filename%20with%20spaces.txt") // returns “..www.myServer.com/filename with spaces.txt"
Replaces certain characters in an URI with escape sequences
string uURIEncode(uri)
The URI to encode
uURIEncode(“..www.myServer.com/filename with spaces.txt")// returns “..www.myServer.com/filename%20with%20spaces.txt"