Hi, I am trying to refactor the jSignature example code and use a Wacom STU-530 to create signatures in Forms. I'm able to draw the signature with the Wacom and see it displayed in the form. I click the Done button and image is created from the canvas just like jSignature and the base64 date is put in the textarea field of the form. But the form image saved in Laserfiche is the original form before the signature is drawn instead of the actual signature like the jSignature example. I can't figure out why this is happening. Any ideas? Thanks.
$(document).ready(function () { /**When the page loads, check if the sig data (hidden) field has a value. If it has a value, decode it and put it in the image, and remove the signature pad and its buttons.**/ var sigvalue = $('.sigdata textarea').text(); var sigrovalue = $('.sigdata .ro').text(); if (sigvalue != '' || sigrovalue != '') { var decoded = htmlDecode(sigvalue == '' ? sigrovalue : sigvalue); var $img = $('<img class=imported></img>'); $img.attr("src", decoded).appendTo('#sigimage'); $('.sigGroup').remove(); //class added to the signature button and image custom HTML fields. $('.sigwarning').hide(); } $.getScript('http://localhost/forms/js/wacom.js', function () { CheckWacomPad(); }); $('#donebutton').click(function () { var sigdata = document.getElementById('wacomdisplay').toDataURL(); $('.sigdata textarea').val(htmlEncode(sigdata)); var $img = $('<img class=imported></img>'); $img.attr("src", sigdata).appendTo('#sigimage'); $('.sigGroup').remove(); if (sigt != 0) clearTimeout(sigt); sigt = setTimeout("ReleaseWacomPad()", padTimeout); }); $('#clearbutton').click(function () { WacomCanvasClear(); WriteImageToWacom(); }); });