How to Base 64 (MIME) Encode and Decode a String

Posted December 15th @ 9:27 pm by m3Rlin

MIME encoding and decoding is used when transferring binary files over the Internet. Every byte is converted to an ASCII character that can be transfered with no problems. This is the code to encode and decode using Base 64 (MIME). You can TMemo’s and TRichEdit’s string text via the Text property. The original code has [...]

How to Resolve a Host Name

Posted December 15th @ 1:10 pm by m3Rlin

Ever needed to convert a host name to an IP number? There is no direct routine available in Delphi for this but we can always code our way through
Here’s the code with error handling:

uses
Winsock;

// The IP number will be returned in string format in the sIP parameter
function HostToIP(sHost: string; var sIP: string): [...]