Add base64 encoding to message attachment example

Following the example may at times result in broken or degraded images due to sending binary data over an ascii transport mechanism. Setting the encoding to base64 fixes this, so we should include this in the example.