function A510(A511){var A446=document.getElementById(A511);if(document.selection){A446.focus();document.selection.createRange().text="%";var A159=A446.value;var match;if(match=/(ss|ae|oe|ue|Ae|Oe|Ue|AE|OE|UE|.)%/i.exec(A159)){var A445=A512(match[1]);if(A445!=0)A159=A159.replace(/(ss|ae|oe|ue|Ae|Oe|Ue|AE|OE|UE|.)%/,A445);else A159=A159.replace(/%/,"");}else {A159=A159.replace(/%/,"");}A446.value=A159;}else if(A446.selectionStart||A446.selectionStart=='0'){var A455=A446.selectionStart;var A456=A446.selectionEnd;var A458=(A446.value).substring(A455,A456);if(!A458){A458=A446.value.substring(A455-1,A455);}var A445=A512(A458);if(A445==0){A446.focus();return 1;}if(A455<A456){A446.value=A446.value.substring(0,A455)+A445+A446.value.substring(A456,A446.value.length);A446.focus();A446.selectionStart=A455;A446.selectionEnd=A456-(A458.length-1);}else {A446.value=A446.value.substring(0,A455-A445.length+(A458=="ß"?1:0))+A445+A446.value.substring(A456+(A458.length-1),A446.value.length);A446.focus();A446.selectionStart=A446.selectionEnd=A455+(A458=="ß"?1:0);}}if(A446.createTextRange)A446.caretPos=document.selection.createRange().duplicate();}function A512(A445){if(A445=="a"){return "à";}else if(A445=="A"){}else if(A445=="à"){return "a";}else if(A445=="e"){return "è";}else if(A445=="i"){return "ì";}else if(A445=="è"){return "e";}else if(A445=="ì"){return "i";}else if(A445=="o"){return "ò";}else if(A445=="O"){}else if(A445=="ò"){return "o";}else if(A445=="u"){return "ù";}else if(A445=="U"){}else if(A445=="ù"){return "u";}return 0;}