title: java script backspace and delete working in IE,not in FireFox
body: <p>I use the following function for decimal validation it was work fine in IE and Chrome not in FF.Backspace and delete key working in IE and Chrome.Not in FireFox</p>
  
  <pre><code>    $('.decimalValidate').live('keypress', function (e) {
          var decimalid = $(this).attr("id");
          var decimalval = $('#' + decimalid).val();
  
          var decimalvalidate = ApplyDecimalFilter(decimalval, e);
          if (decimalvalidate == false) return false;
      });
  
  
  
      function ApplyDecimalFilter(id, event)
          {
              try {
                  return NewDecimalFilter(id, event);
              } catch (e) {
                  alert(e.message);
              }
          }
  
      function NewDecimalFilter(o, event) {
              if (event.which &gt; 47 &amp;&amp; event.which &lt; 58) {
                  return true;
              }
              if (event.which == 50 ||(event.which == 8 || event.which == 46) &amp;&amp; o.indexOf('.') == -1)  {
                  return true;
              }
              return false;
          }
  </code></pre>
  
  <p>this if condition not working in FireFox only.this is used to enter the only one dot symbol</p>
  
  <pre><code>if (event.which == 50 ||(event.which == 8 || event.which == 46) &amp;&amp; o.indexOf('.') == -1)  {
                  return true;
              }
  </code></pre>