Skip to content

Instantly share code, notes, and snippets.

@sampathsl
Created October 25, 2016 05:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sampathsl/bf7c760f6bbb1ab28f56b1643995840c to your computer and use it in GitHub Desktop.
Save sampathsl/bf7c760f6bbb1ab28f56b1643995840c to your computer and use it in GitHub Desktop.
Disable drop and paste in text boxes
function removeDropPaste()
{
jQuery(".numeric").bind("paste", function (e) {
return false;
});
jQuery(".numeric").bind("drop", function (e) {
return false;
});
}
// remove the drop and paste on text boxes
jQuery(document).ready(function(){
removeDropPaste();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment