title: Javascript RegExp + Word boundaries + unicode characters
body: <p>I am building search and I am going to use javascript autocomplete with it. I am from Finland (finnish language) so I have to deal with some special characters like ä, ö and å</p>
  
  <p>When user types text in to the search input field I try to match the text to data.</p>
  
  <p>Here is simple example that is not working correctly if user types for example "ää". Same thing with "äl"</p>
  
  <pre><code>var title = "this is simple string with finnish word tämä on ääkköstesti älkää ihmetelkö";
  // Does not work
  var searchterm = "äl";
  
  // does not work
  //var searchterm = "ää";
  
  // Works
  //var searchterm = "wi";
  
  if ( new RegExp("\\b"+searchterm, "gi").test(title) ) {
      $("#result").html("Match: ("+searchterm+"): "+title);
  } else {
      $("#result").html("nothing found with term: "+searchterm);   
  }
  </code></pre>
  
  <p><a href="http://jsfiddle.net/7TsxB/" rel="noreferrer">http://jsfiddle.net/7TsxB/</a></p>
  
  <p>So how can I get those ä,ö and å characters to work with javascript regex? </p>
  
  <p>I think I should use unicode codes but how should I do that? Codes for those characters are:
  [\u00C4,\u00E4,\u00C5,\u00E5,\u00D6,\u00F6]</p>
  
  <p>=> äÄåÅöÖ</p>