Closed harikrishna149 closed 8 years ago
Try using ismodified to check if the canvas has any content
Hi Brinley,
isModified method is working fine when cavas has no content. but how can we validate the signature using isModidied and getdata length?.
I am using both the methods and i am getting some length of canvas conent. how to validate that canvas content length?
Thanks, Harikrishna
getData on a canvas will always return data even for a blank canvas. Perhaps you can save the data for your blank canvas and use that to compare if there is any content.
Why not use the method like this: '$sigdiv.jSignature('getData', 'native').length'? if the length is 0, then the canvas has no content, else the canvas has any content and the lenth is eauals to the number of strokes
Hi,
I am working with jSignature in my application using asp.net mvc angularjs. I want to do vallidate this signature as required. I tried using getdata method when canvas is empty and i get the signature length is 2430. how can i validate the signature. please help me asap.
Code: $scope.saveSignature = function () { var data = $("#signature").jSignature("getData"); alert(data.length); $scope.SignData = sig.jSignature('getData'); }
I want to validate the signature in saveSignature function. Please help me