encode Summary Encodes the input string with base64 encoding. Usage public static string encode(string data) Returns A base64-encoded string. Parameters data The data to encode with base64. Description Encodes the input string with the base64 encoding scheme defined in RFC 2045 - MIME (Multipurpose Internet Mail Extensions). Examples Basic Usage 1234567import System;import System.Encoding; string sentence = "This is a test."; string encoded = Base64.encode(sentence);Console.log(encoded); // "VGhpcyBpcyBhIHRlc3Qu" Share HTML | BBCode | Direct Link