Created
September 1, 2016 16:50
-
-
Save hmelenok/7a1e7b0910c761442f6be1ddebe7e014 to your computer and use it in GitHub Desktop.
function to decode in js gmail base64 strings to normal UTF8 language
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function base64DecodetoUTF8(string) { | |
return decodeURIComponent(escape(atob(string.split('-').join('+').split('_').join('/')) )); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment