call function with parameter in jquery

Posted by Klbaiju under jQuery on 8/18/2013 | Points: 10 | Views : 1780 | Status : [Member] | Replies : 1
$("#<%= txtfare.ClientID%>").keydown(function (e) {
if (e.shiftKey)
e.preventDefault();
else {
var nKeyCode = e.keyCode;
//Ignore Backspace and Tab keys
if (nKeyCode == 8 || nKeyCode == 9)
return;
if (nKeyCode < 95) {
if (nKeyCode < 48 || nKeyCode > 57)
e.preventDefault();
}
else {
if (nKeyCode < 96 || nKeyCode > 105)
e.preventDefault();
}
}
});




Responses

Posted by: Bandi on: 8/19/2013 [Member] [MVP] Platinum | Points: 25

Up
0
Down
refer these links
http://forum.jquery.com/topic/how-to-pass-function-with-parameter-as-parameter
http://www.phpeveryday.com/articles/jQuery-Plugin-Development-Method-Parameters-P978.html

Mark This Response as Answer
--
Chandu
http://www.dotnetfunda.com/images/dnfmvp.gif

Klbaiju, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response