Crypto
crypto.encode
Shared
Encodes a string into equivalent base64 string
Syntax
local result = crypto.encode(input)Parameters
| Type | Name | Description |
|---|---|---|
string | input | String containing data to be encoded |
Returns
| Type | Name | Description |
|---|---|---|
string / bool | result | Encoded string on successful execution, or false on failure |
Examples
local input = "Hello World"
engine.print("Input:", input)
engine.print("Encoded:", crypto.encode(input))