MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_NextPart" ------=_NextPart Content-Location: file:///X:/ Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset="us-ascii"

Embed Base64 encoded image into web pages

How this is made?

  1. Convert Image Binary File into base64 encoded String
  2. For Internet Explorer, use MHTML + VML to render base64 encoded String as Image
  3. For Firefox, Safari, and Opera, use Base64 encoding Image
  4. Here is the PHP source code

Demo

------=_NextPart Content-Location: file:///X:/www.yahoo.com Content-Transfer-Encoding: base64 Content-Type: image/png ------=_NextPart Content-Location: file:///X:/www.google.com Content-Transfer-Encoding: base64 Content-Type: image/jpg