Encode datas using base64, only for mysql insert and pop offline message

In some scense, face are not saved completly in mysql, so using base64 to encode datas maybe prevent the datas losing.  
In codes, adding functions to pares xml body to encode when inserting before mysql and decode xml body when poping mysql.