-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
PDF does not show images from online #141
Comments
I got the same issue. But it's quite different. PDF created but it show empty space, not image. |
I have the same issue as solomondn on React and can't work around it since I can't store the images locally. |
//this is my code for it
|
I am also having a similar issue. Wont detect any external images at all. As a workaround you can convert your images to Base64 For example. Using
Yields
Using Base64 (Or locally stored images)
@axiom88-guru Does this do anything for you?
Once again, You can only retrieve images with servers that have CORS enabled. |
@PhilipTKC thanks for your response. |
I got the exact same issue with solomondn, have you fix it? |
Converting the image to Base64 sorted me out. |
@bdwellons can u share me the code u used to convert images to base64? |
@bdwellons +1 to the code. I tried in JS doing img.src=, the html page showed the image correctly, but it still wouldn't show in the generated PDF. |
Hi! do you have the code that can be used to convert images to base64? |
Try to specify "allowTaint" parameter to "true" in html2canvas object opt = { |
Thank you @PrasanthPerumalsamy |
This my code 100% best working! |
To anyone wondering how to enable CORS (Cross-origin resource sharing) on Firebase storage so your app can access photos saved there using this plugin by simply writing something like Here's a link to an additional resource you may find useful: https://stackoverflow.com/a/37765371/17246058 You will also need to make sure you set
As an example, you can create a pdf with this plugin by then putting: |
I had the same issue and the following configs work with me just fine |
Hi ,
I use Angular 5 and this is used for my Angular method.
After exporting a pdf, I am unable to see any images from online but it shows locally stored images.
Here is the example of image online.
https://s3.amazonaws.com/images.anterasoftware.com/5b6c5886622d5Screen_Shot_2018-06-27_at_10.37.03_AM.png
Please help, @eKoopmans
Regards.
The text was updated successfully, but these errors were encountered: