willowsystems / jSignature

jQuery plugin - draw signature in browser.
720 stars 266 forks source link

How to export data to base30 after ("setData","data:image/png;base64,"+base64String) successfully. #102

Open thangvo1984 opened 5 years ago

thangvo1984 commented 5 years ago

Hi,

I have a base64 image string (for example: "iVBORw0KGgoAAAANSUhEUgAAAkQAAAEsCAYAAAAir6zwAAAgAE...") I imported it to JSignature by code: $('#signature').jSignature("setData","data:image/png;base64,"+base64String); It worked fine. Image displayed successfully on JSignature. Then I exported that image on JSignature to base30 to save to database by code: $('#signature').jSignature('getData', "base30"); It return: [ 0: "image/jsignature;base30", 1: "" ]. Could you help me method that export data after I imported like user drawing their signature on the JSignature by themselves.

Please help me. Thank you very much.