Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Base64 Code Is not Properly Encoded #29

Open
praveen-vishnu opened this issue Sep 28, 2018 · 4 comments
Open

Base64 Code Is not Properly Encoded #29

praveen-vishnu opened this issue Sep 28, 2018 · 4 comments

Comments

@praveen-vishnu
Copy link

I have Converted Image to Base64 But Output Of the is not working as expected
i'm Unable to decode it Back

@akildemir
Copy link

Same problem here. It doesn't show the encoded picture in the app view.

@frankyso
Copy link

i think its because the encoded file added new lines with some new character, i tried it already.
just remove the \n in the base64 string, then it should works.

@akildemir
Copy link

Frankyso thanks man but I am not using base64 anymore. It is really no good especially in an ionic app. Sometimes I was getting almost 2mb data for 300kb image. And for css to process this much data it was taking some time to load picture. And if user choose a 2mb image from the gallery, it was taking around 3 minute for the app to show the pic in view.

@Nayan014
Copy link

Remove \n from base64 data after that it will work

base64.replace(/\n/g, '')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants