Adding base64 encode function to media manager

Encode media files in base64 could be useful for connector export purpose.

Bug fix: [no]
Feature addition: [yes]
Backwards compatibility break: [no]
Unit test passes: [yes|no]
Behat scenarios passes: [yes|no]
Checkstyle issues: [no]*
ChangeLog updated: [no]