title: How to replace UTF-8 letters to similar latin letters using Jquery or Javascript
body: <p>How do I replace all UTF-8 letters like Ė È É Ê Ë Ą Č and so on to similar latin letters. For example the output of the string <code>ĖÈÉÊËĄČ</code> would be <code>EEEEEAC</code> using Javascript or Jquery?</p>
  
  <p>technique described in this question
  <a href="https://stackoverflow.com/questions/5396560/how-do-i-convert-special-utf-8-chars-to-their-iso-8859-1-equivalent-using-javasc">How do I convert special UTF-8 chars to their iso-8859-1 equivalent using javascript?</a> returns the result as UTF-8 byte sequence so result of <code>encodeURIComponent("å")</code> would be equal to <code>%C3%A5</code> and in my case it should be <code>a</code></p>
  
  <p>The question may be a duplicate to this one <a href="https://stackoverflow.com/questions/990904/javascript-remove-accents-diacritics-in-strings">Remove accents/diacritics in a string in JavaScript</a> but all the solutions provided in that question is by hard coding all possible characters and to map that to the one you want  to replace with and that's not very clean solution. </p>