replace char from string for turkish configuration
<p>I had a chat function in my site and this function did not display Turkish characters properly. So that, i wrote this function below but it returns nothing. Where did it go wrong? Text gets comments as string.</p>

<pre><code>function FindAndReplaceAll(text) 
{
  var normal = new Array("Ä±","Å?","Ã¼","Ã§","Ã¶","Ä?","ÅŸ","Ã‡","Ä°","ÄŸ","Åž","Ã–","Ãœ","Ä±","Å?","Ã§","Ã¶","Ä?","ÅŸ","Ã‡","Ä°","ÄŸ","Åž","Ã–","Ãœ","Ã¼","ÄŸ");
  var turkish = new Array("ı","ş","ü","ç","ö","ğ","ş","Ç","i","ğ","Ş","Ö","Ü","ı", "ş", "ç", "ö", "ğ", "ş", "Ç", "i", "ğ", "Ş", "Ö", "Ü", "ü", "ğ");

  for (var i = 0; i &lt; text.length; i++) 
  {
    for(var j = 0; j &lt; 27;j++)
        {
            if(text.charAt(i) == normal[j])
            {
                text.charAt(i) = turkish[j];    
            }

        }
  }


  return text;
}
</code></pre>

<p>Thanks</p>
