What is BASE64 encoding

BASE64 encoding performs any binary data as printable text. Such text representation allows to pass binary data via a channel or keep them in a storage designed for text only. The editor uses BASE64 encoding to return the image to JavaScript as a text string, or accept image as applet's parameter value.

Example:

This image can be kept in a binary file, but encoded with BASE64 it looks as:

iVBORw0KGgoAAAANSUhEUgAAACAAAAATBAMAAAADuhLEAAAABGdBTUEAALGP
C/xhBQAAAAFzUkdCAdnJLH8AAAAPUExURYSEhP///wAAAP//AP8AACykMFsA
AABsSURBVHjahdDBDcMwDENRWhsw9AJRuwCBLuAi+8+UQ+rGTg75NwkPECBg
LlDmAuBUoCyZfapbm4Tr1gJlybVvPt/XKMz6boHyX4iWBmGKdBf5i6cwSVpX
4fGKnoRpqQsdV+1TmLYkBW4Pyks7gc8WIpISYokAAAAASUVORK5CYII=

The encoding technique can be found here: http://www.ietf.org/rfc/rfc1521.txt, but most likely it's unnecessary because many server-side scripting languages support functions for BASE64 encoding/decoding.

BTW Did you know that e-mail software uses BASE64 encoding to hold attached files? This is because the widely used e-mail protocols SMTP and POP3 are not capable to manage binary content.