Posts

Showing posts with the label jquery

How to take a screenshot or make a image of current screen using php and javascript with jquery or make a pdf file of current scrren

For create a image of current screen using javascript add below script into your file <script type="text/javascript"> function printDiv() {     jQuery('.year_box').remove(); // add your container id for capcture screen here i write "main_panel_body" for example     html2canvas([document.getElementById('main_panel_body')], {           onrendered: function(canvas)          {             var img = canvas.toDataURL();             jQuery('.overlay_box').show(); // calling ajax method for create image from binary data             $.post("save.php", {data: img}, function (file) {                 jQuery('.overlay_box').hide();  ...

JQuery html form disable form submit on press enter

Just use below code and replace your id with "rjform" jQuery('#rjform').on('keyup keypress', function(e) {   var code = e.keyCode || e.which;   if (code == 13) {     e.preventDefault();     return false;   } });