title: jQuery: modifying input value on keypress
body: <p>Whenever a dot '.' is typed in my input (type=number) field, I want it replaced by a comma ','.</p>
  
  <pre><code>$(box).find('input[type=number]').keypress(function(evt){
          if(evt.which==46){
              $(this).val($(this).val()+',');
              evt.preventDefault();
          }
      });
  </code></pre>
  
  <p>The event is well fired, but instead, the field gets totally empty. What's wrong?</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>The reason why I'm doing this is that Chrome (latest version), contrary to the HTML5 recommandation, use comma and discard dot in input type=number. I'm currently only developing for Chrome cause I can't test my app somewhere else for the moment. Any comment on this (abnormal ?) situation would be appreciated.</p>