Posted By

feeorin on 09/17/11


Tagged

replace remove characters greek


Versions (?)

Removing Greek Glyphs (eg ά, Ά)


 / Published in: ActionScript 3
 

  1. public static function removeGreekGlyphs ($value:String):String {
  2.  
  3. $value = $value.replace(/[άΆ]/g, "α");
  4. $value = $value.replace(/[ΊΪίΐϊ]/g, "ι");
  5. $value = $value.replace(/[όΌ]/g, "ο");
  6. $value = $value.replace(/[ώΏ]/g, "ω");
  7. $value = $value.replace(/[ήΉ]/g, "η");
  8. $value = $value.replace(/[ύΎΰϋΫ]/g, "υ");
  9. $value = $value.replace(/[έΈ]/g, "ε");
  10. $value = $value.replace(/[ς]/g, "σ");
  11. return $value;
  12. }

Report this snippet  

You need to login to post a comment.