Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Increase the height of JSignature input area

I am using JSignature to accept the signature. How can i increase the default height? I tried giving height to the signature div but not working as expected.

Code:
<div id="signature" style="background-color:#fff9cb;border:0px;height:200px"></div>

How to fix this?

like image 683
user3554548 Avatar asked Oct 28 '25 23:10

user3554548


2 Answers

replace this line in jSignature Sample

var $sigdiv = $("#signature").jSignature({ 'UndoButton': true })

to

var $sigdiv = $("#signature").jSignature({ 'UndoButton': true, 'width': 400, 'height': 400 })
like image 82
Mohammadreza Zandi Avatar answered Oct 31 '25 11:10

Mohammadreza Zandi


I've had trouble altering the size or the line width of the signature box in <div> (capture) and <img> (display) tags. Try modifying the size with jQuery (and make sure you have jSignature.js added to your project):

<div id="mySignatureBox" style="background:#000000; color:#ffffff"></div>   

$('#mySignatureBox').jSignature({ lineWidth: 1, width: 700, height: 200 });
like image 33
Haywain Avatar answered Oct 31 '25 12:10

Haywain