Function Bin2Base64() Foundation

Converts a string to a base64 encoded string.

Syntax
Bin2Base64( <cString>, [<nLineLen>] ) --> cEncodedString
Parameters
<cString>
The parameter cString is a binary string that can contain any character.
<nLineLen>
<nLineLen> is a positive integer value specifying the maximum line length of cEncodedString. The default value is 0 in which case the line length is unrestricted and no line breaks are inserted into the returned string.
Return

This function returns a base64 encoded string.

Description

The function Bin2Base64() encodes the characters cString according to the base64 algorithm. The return value of the function Bin2Base64() contains only human readable characters and is suitable for the transport over channels that only support text content reliably.

If the encoded string must comply with the MIME content transfer encoding standard, pass the numeric value 72 in the parameter <nLineLen>.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.