<! DOCTYPE html > < html lang = "en" > < head > < meta charset = "UTF-8" > < meta name = "viewport" content = "width=device-width, initial-scale=1.0" > < title > Document </ title > </ head > < body > < script src = "//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js" ></ script > < script src = "//cdnjs.cloudflare.com/ajax/libs/jspdf/1.2.61/jspdf.debug.js" ></ script > < script > $ ( document ). ready ( function () { var doc = new jsPDF (); $ ( '#cmd' ). click ( function () { doc . fromHTML ( $ ( '#content' ). html (), 15 , 15 , { 'width' : 170 , }, function () { doc . save ( 'sample-file.pdf' ) }); }); }); </ script > ...