Skip to content Skip to sidebar Skip to footer

How To Add Image In Jspdf?

I have tried this code for add a image,but here Image has been not adding with pdf. function RunCode() { var imgData = 'data:pubali.jpg/jpeg;'; var doc = new jsPDF(

Solution 1:

  1. You Will make your image into a Data url.
  2. Go to this link http://dopiaza.org/tools/datauri/index.php for convert your image into a url.
  3. Then follow this link http://mrrio.github.io/jsPDF/ add your data url like this.

Solution 2:

problem is you are not find out datauri,

 [1] : [http://dopiaza.org/tools/datauri/index.php] 

click this link upload your image.find out your datauri.

Post a Comment for "How To Add Image In Jspdf?"