How String.fromCharCode function work for mobile key board in html input field

I want to capture the keyboard key code and convert it to characters. I am using the String.fromCharCode javascript function but it only works on a computer keyboard it is not working with a mobile keypad. Any help will be appreciated.

$(".inputsmeter").keyup(function (e) { 
  let key = e.which; 
  let c = String.fromCharCode(key); 
  alert(c); 
});


Comments

Popular posts from this blog

Today Walkin 14th-Sept

Spring Elasticsearch Operations

Hibernate Search - Elasticsearch with JSON manipulation