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

Can we open a base64 format pdf using this plugin? can you provide a small demo snippet for it? Would be of a great help. Thanks in advance.. #4

Open
Gamerakki opened this issue Feb 16, 2016 · 2 comments

Comments

@Gamerakki
Copy link

No description provided.

@loicminghetti
Copy link
Owner

You cannot pass a base64 format pdf in options.source instead of an URL. This is not supported by PDFJS.

Based on http://stackoverflow.com/questions/12092633/pdf-js-rendering-a-pdf-file-using-a-base64-file-source-instead-of-url, it seems that if you first convert the base64 string to a Uint8Array, and then set it to options.source, it could work.

I haven't tried it out, let me know if it works.

@Gamerakki
Copy link
Author

Okay give sometime for me to check and try out for above link you gave :D

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

2 participants