Encoding & cryptographyReference
crypt.base64encode
Encode a binary string as Base64 text.
Aliases
base64encodebase64_encodebase64.encodecrypt.base64_encodecrypt.base64.encodeDetails#
Encode a binary string as Base64 text. Base64 text with standard alphabet and padding.
Signature#
crypt.base64encode(data: string): stringParameters#
| Parameter | Type | Description |
|---|---|---|
data | string | Bytes to encode; embedded NUL bytes are supported. |
Returns#
Base64 text with standard alphabet and padding.
Examples#
Local example
print(crypt.base64encode("hello")) -- aGVsbG8=