Skip to content

Instantly share code, notes, and snippets.

@pr4v33n
Created July 28, 2011 13:21
Show Gist options
  • Save pr4v33n/1111529 to your computer and use it in GitHub Desktop.
Save pr4v33n/1111529 to your computer and use it in GitHub Desktop.
En to Jp phonetic translation
// Paste the line below in Adress bar to translate
javascript:void((function(){var en=prompt("Name in english:");var ma={'a':'ka','b':'tu','c':'mi','d':'te','e':'ku','f':'lu','g':'ji','h':'ri','i':'ki','j':'zu','k':'me','l':'ta','m':'rin','n':'to','o':'mo','p':'no','q':'ke','r':'shi','s':'ari','t':'chi','u':'do','v':'ru','w':'mei','x':'na','y':'fu','z':'zi'};var jn='';for(var i=0;i<en.length;++i){ch=en.charAt(i).toLowerCase();if(ch in ma){jn+=ma[ch];}else{jn+=ch;}}alert(jn);})())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment