Difference between revisions 254170 and 254171 on cawiktionary/*Adaptat de en.wiktionary.org/wiki/User:Yair_rand/newentrywiz.js */ var necdata=new Array() necdata['pos']="nom" necdata['pos2']="Nom" var necdefs=new Array() necdefs[0]=['',[],[],[]] //accep,ex.,cit.,refs. var necpost=new Array();//Categ. gram. for(i=0;i<=3;i++) {necpost[i]=new Array()}//categ.,declin. var neccode='ca' var necpostlangtext=new Array() var wS='\n\'\'\''+wgTitle+'\'\'\''; function Deva2AFI(text, wISO) { var typo_def = new Array ( "(क)", "kə", "(ख)", "kʰə", "(ग)", "gə", "(घ)", "gʱə", "(ङ)", "ŋə", "(ह)", "hə", "(च)", "tʃə", "(छ)", "tʃʰə", "(ज)", "dʒə", "(झ)", "dʒʱə", "(ञ)", "ɲə", "(य)", "jə", "(श)", "ʃə", "(ट)", "ʈə", "(ठ)", "ʈʰə", "(ड)", "ɖə", "(ढ)", "ɖʱə", "(ण)", "ɳə", "(र)", "rə", "(ष)", "ʂə", "(त)", "t̪ə", "(थ)", "t̪ʰə", "(द)", "d̪ə", "(ध)", "d̪ʱə", "(न)", "nə", "(ल)", "lə", "(स)", "sə", "(प)", "pə", "(फ)", "pʰə", "(ब)", "bə", "(भ)", "bʱə", "(म)", "mə", "(व)", "ʋə", "(्)", "[<-elidir]", "(ँ)", "ṃ", "(ं)", "ṃ", "(ः)", "h", "(अ)", "ə", "(आ)", "aː", "(ा)", "aː", "(इ)", "ɪ", "(ि)", "ɪ", "(ई)", "i", "(ी)", "i", "(उ)", "ʊ", "(ु)", "ʊ", "(ऊ)", "u", "(ू)", "u", "(ऋ)", "r", "(ृ)", "r", "(ए)", "e", "(े)", "e", "(ऐ)", "ɛ", "(ै)", "ɛ", "(ओ)", "o", "(ो)", "o", "(औ)", "au", "(ौ)", "au", "(əə)", "ə", "(əa)", "a", "(əɪ)", "ɪ", "(əi)", "i", "(əʊ)", "ʊ", "(əu)", "u", "(əe)", "e", "(əɛ)", "ɛ", "(ड़)", "ɽ", "(ढ़)", "ɽʱ" ); var lng = typo_def.length; if (lng % 2 != 0) return text; for (var i = 0; i < lng; i += 2) { search = new RegExp(typo_def[i + 0], "g"); text = text.replace(search, typo_def[i + 1]); } if(wISO=="mr") { text = text.replace('dʒ','ɟʝ'); text = text.replace('n','n̪'); text = text.replace('ʋ','v'); text = text.replace('ɪ','i'); text = text.replace('ʊ','u'); text = text.replace('ɛ','əi'); text = text.replace('ऑ','ɔ'); text = text.replace('अॅ','æ'); } return text; } function Deva2IAST(text) { var typo_def = new Array ( "(क)", "ka", "(ख)", "kha", "(ग)", "ga", "(घ)", "gha", "(ङ)", "ṅa", "(ह)", "ha", "(च)", "ca", "(छ)", "cha", "(ज)", "ja", "(झ)", "jha", "(ञ)", "ña", "(य)", "ya", "(श)", "śa", "(ट)", "ṭa", "(ठ)", "ṭha", "(ड)", "ḍa", "(ढ)", "ḍha", "(ण)", "ṇa", "(र)", "ra", "(ष)", "ṣa", "(त)", "ta", "(थ)", "tha", "(द)", "da", "(ध)", "dha", "(न)", "na", "(ल)", "la", "(स)", "sa", "(प)", "pa", "(फ)", "pha", "(ब)", "ba", "(भ)", "bha", "(म)", "ma", "(व)", "va", "(्)", "[<-elidir]", "(ँ)", "ṃ", "(ं)", "ṃ", "(ः)", "ḥ", "(अ)", "a", "(आ)", "ā", "(ा)", "ā", "(इ)", "i", "(ि)", "i", "(ई)", "ī", "(ी)", "ī", "(उ)", "u", "(ु)", "u", "(ऊ)", "ū", "(ू)", "ū", "(ai)", "i", "(au)", "u", "(ऋ)", "ŕ", "(ृ)", "ŕ", "(ए)", "e", "(े)", "e", "(ऐ)", "ai", "(ै)", "ai", "(ओ)", "o", "(ो)", "o", "(औ)", "au", "(ौ)", "au", "(aa)", "a", "(aā)", "ā", "(aī)", "ī", "(aū)", "ū", "(ae)", "e", "(ड़)", "ṛ", "(ढ़)", "ṛh" ); var lng = typo_def.length; if (lng % 2 != 0) return text; for (var i = 0; i < lng; i += 2) { search = new RegExp(typo_def[i + 0], "g"); text = text.replace(search, typo_def[i + 1]); } return text; } var necinfls={ ca: {nom:['{'+'{-nom-|ca','',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Femení i masculí singular','|mf}}'+wS+' {'+'{m}} i {'+'{f}} ({'+'{p}} [['+wgTitle+'s]])'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení i masculí plural','|mf|plural}}'+wS+' {'+'{m}} i {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]], adjectiu:['{'+'{-adj-|ca',' {'+'{4 formes|'+wgTitle+'|'+wgTitle+'s|'+wgTitle+'|'+wgTitle+'s}}',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Invariable singular','|i}}'+wS+' {'+'{i}} {'+'{pl.|'+wgTitle+'s}}'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Invariable plural','|i|plural}}'+wS+' {'+'{i}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]], formaverbal:['{'+'{-formaverbal-}}\n#{{ca-verb forma','|nodot=1}}',['— Persona','',[['Primera','|persona=1'],['Segona','|persona=2'],['Tercera','|persona=3'],['Impersonal','|persona=0']]],['— Nombre','',[['Singular','|nombre=s'],['Plural','|nombre=p']]],['— Temps','',[['Present','|temps=pres'],['Imperfet','|temps=imp'],['Passat','|temps=passat'],['Condicional','|temps=cond']]],['— Mode','',[['Indicatiu','|mode=ind'],['Subjuntiu','|mode=subj'],['Imperatiu','|mode=imp'],['Condicional','|mode=ind'],['Participi','|mode=par'],['Gerundi','|mode=ger']]],['— Gènere','',[['Masculí','|gènere=m'],['Femení','|gènere=f']]],['— Verb','',[['input',' ','|verb=']]]], pronom:['{'+'{-pronom-|ca',' {'+'{4 formes|'+wgTitle+'|'+wgTitle+'s|'+wgTitle+'|'+wgTitle+'s}}',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Invariable singular','|i}}'+wS+' {'+'{i}} {'+'{pl.|'+wgTitle+'s}}'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Invariable plural','|i|plural}}'+wS+' {'+'{i}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]] }, en: {nom:['{'+'{-nom-|en','',['— Nombre','',[['Singular','}}'+wS+' {'+'{pl.|'+wgTitle+'s}}'],['Plural','|Nombre=plural}}'+wS+' {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]], verb:['{'+'{-verb-|en}}\n{'+'{en.v.conj','',['— Temps','',[['Infinitiu','|'+wgTitle+'s|'+wgTitle+'ing|'+wgTitle+'ed|'+wgTitle+'ed}}']]]], adjectiu:['{'+'{','',['— Forma','',[['Demostratiu','-adj-|en}}\n{'+'{en-adj}}'],['Comparatiu','-formaadjectival-|en}}'+wS]]]] }, fr: {nom:['{'+'{-nom-|fr','',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Femení i masculí singular','|mf}}'+wS+' {'+'{m}} i {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení i masculí plural','|mf|plural}}'+wS+' {'+'{m}} i {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]] }, hi: {nom:['{'+'{-nom-|hi','',['— Gènere','',[['Masculí','|m}}\n#'+'{'+'{m}} '],['Femení','|f}}\n#'+'{'+'{f}} ']]]] }, mr: {nom:['{'+'{-nom-|mr','',['— Gènere','',[['Masculí','|m}}\n#'+'{'+'{m}} '],['Femení','|f}}\n#'+'{'+'{f}} ']]]] }, sa: {nom:['{'+'{-nom-|sa','',['— Gènere','',[['Masculí','|m}}\n#'+'{'+'{m}} '],['Femení','|f}}\n#'+'{'+'{f}} ']]]] }, la: {nom:['{'+'{-nom-|la','',['— Gènere','',[['Masculí','|m}}'+wS+' {'+'{m}}'],['Femení','|f}}'+wS+' {'+'{f}}'],['Neutre','|n}}'+wS+' {'+'{n}}']]]] }, es: {nom:['{'+'{-nom-|es','',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Femení i masculí singular','|mf}}'+wS+' {'+'{m}} i {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení i masculí plural','|mf|plural}}'+wS+' {'+'{m}} i {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]], formaverbal:['{'+'{-formaverbal-}}\n#{{es-verb forma','|nodot=1}}',['— Persona','',[['Primera','|persona=1'],['Segona','|persona=2'],['Tercera','|persona=3'],['Impersonal','|persona=0']]],['— Nombre','',[['Singular','|nombre=s'],['Plural','|nombre=p']]],['— Temps','',[['Present','|temps=pres'],['Imperfet','|temps=imp'],['Passat','|temps=passat'],['Condicional','|temps=cond']]],['— Mode','',[['Indicatiu','|mode=ind'],['Subjuntiu','|mode=subj'],['Imperatiu','|mode=imp'],['Condicional','|mode=ind'],['Participi','|mode=par'],['Gerundi','|mode=ger']]],['— Gènere','',[['Masculí','|gènere=m'],['Femení','|gènere=f']]],['— Verb','',[['input',' ','|verb=']]]], pronom:['{'+'{-pronom-|es',' {'+'{4 formes|'+wgTitle+'|'+wgTitle+'s|'+wgTitle+'|'+wgTitle+'s}}',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Invariable singular','|i}}'+wS+' {'+'{i}} {'+'{pl.|'+wgTitle+'s}}'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Invariable plural','|i|plural}}'+wS+' {'+'{i}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]], adjectiu:['{'+'{-adj-|es',' {'+'{4 formes|'+wgTitle+'|'+wgTitle+'s|'+wgTitle+'|'+wgTitle+'s}}',['— Gènere i nombre','',[['Masculí singular','|m}}'+wS+' {'+'{m}} {'+'{pl.|'+wgTitle+'s}}'],['Femení singular','|f}}'+wS+' {'+'{f}} {'+'{pl.|'+wgTitle+'s}}'],['Invariable singular','|i}}'+wS+' {'+'{i}} {'+'{pl.|'+wgTitle+'s}}'],['Masculí plural','|m|plural}}'+wS+' {'+'{m}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Femení plural','|f|plural}}'+wS+' {'+'{f}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])'],['Invariable plural','|i|plural}}'+wS+' {'+'{i}} {'+'{p}} (\'\'sing.\'\' [['+wgTitle.substr(0,wgTitle.length-1)+']])']]]] } } var necetym;var necpron;var nechomof;var necparon;var necanag; var necheadingorder=new Array('Sinònims','Traduccions','Categoria','Declinació') var necinputadvanced="" var necposlist=new Array('Nom','Verb','Adjectiu','Adverbi','Forma verbal','Pronom','Conjunció','Interjecció','Preposició','Nom propi','Prenom','Article','Prefix','Infix','Sufix','Numerals','Acrònim','Sigles','Símbol','Locucions','Forma adjectival') function necfunction2() { //OPCIONS DE CREACIÓ var x="@@@*** PROVES @@@*** Codi de llengua: <input type=text value='ca' id='necinput' onKeyUp='neccode=this.value;necfunction();AFI();necfunction4();necfunction()' onblur=if(necCleanLangCode(this.value)){this.value=necCleanLangCode(this.value)};neccode=this.value;document.getElementById('nectransspan').style.display=((this.value=='ca')?'':'none');if(/^[a-z]{2,3}(-[a-z\-]{1,7})?$/.test(this.value)){document.getElementById('neclangerror').style.display='none'}else{document.getElementById('neclangerror').style.display=''};necfunction();necfunction4();necfunction();necdefupdate() title='Les 2 o 3 lletres del codi ISO-639'></input><span id=neclangerror style=display:none;color:red> ERROR: CODI DE LLENGUA INVÀLID</span><br>Categoria gramatical: "; for(i=0;i<4;i++) { //omple Nom,Verb,Adjectiu,Adverbi x+="<a id='necinputpos"+necposlist[i]+"' href=javascript: onclick=document.getElementById('necinputpos'+necdata['pos2']).style.fontWeight='';necdata['pos2']='"+necposlist[i]+"';necdata['pos']='"+necposlist[i].toLowerCase()+"';this.style.fontWeight='bold';necfunction4();necfunction()";if(!i){x+=" style='font-weight:bold'"};x+=">"+necposlist[i]+"</a>, "; } //mostra la llista de categs. gram (a partir del 4è) x+="<span id='necinputpos'>Altre: <input type=text onKeyUp=\"document.getElementById('necinputpos'+necdata['pos2']).style.fontWeight='';necdata['pos2']=this.value;necdata['pos']=this.value.toLowerCase().replace(/ /g,'');this.parentNode.setAttribute('ID','necinputpos'+this.value);document.getElementById('necinputpos'+necdata['pos2']).style.fontWeight='bold';necfunction();necfunction4()\" /><select onchange=\"document.getElementById('necinputpos'+necdata['pos2']).style.fontWeight='';necdata['pos2']=this.value;necdata['pos']=this.value.toLowerCase().replace(/ /g,'');this.parentNode.setAttribute('ID','necinputpos'+this.value);document.getElementById('necinputpos'+necdata['pos2']).style.fontWeight='bold';necfunction();necfunction4()\"><option value=''>Seleccioneu</option>"; for(i in necposlist) { if(i>3){x+="<option>"+necposlist[i]+"</option>";} } x+="</select></span><span id=necinfls></span><br>Altres dades: <a href=javascript: id=necSynonymsbutton onclick=necpost[0][necpost[0].length]=['',''];necpostbox();necfunction();this.style.fontWeight='bold' title='Afegiu secció de sinònims'>Sinònims</a>, <span id=nectransspan><a href=javascript: id=nectransbutton onclick=necpost[1][necpost[1].length]=['',''];necpostbox();necfunction();this.style.fontWeight='bold' title='Afegiu secció de traduccions'>Traduccions</a>, </span>Més: <select onchange=necpostbox(this.value);this.selectedIndex=0;necfunction()><option select='selected'>Seleccioneu</option>"; for(i in necheadingorder) {//excepte sense ús, sinònims i traduccions if(i!=0&&i!=1){x+="<option value="+i+">"+necheadingorder[i]+"</option>"} } x+="</select><br><span id=necpostbox></span><span id='necdefs'>Accepció: <input type=text id='necinput3' onKeyUp=necdefs[0][0]=this.value;necfunction() /><br></span>Informació inicial: <a href=javascript:necdefs.push(['',[],[],[]]);uNec() title='Afegiu nova accepció'>Nova accepció</a>, <a href=javascript: id=necpronbutton onclick=document.getElementById('necpronspan').style.display='';necpron=document.getElementById('necproninput').value;necfunction();this.style.fontWeight='bold' title='Afegiu secció de Pronúcia'>Pronúncia</a>, <a href=javascript: id=nechomofbutton onclick=document.getElementById('nechomofspan').style.display='';nechomof=document.getElementById('nechomofinput').value;necfunction();this.style.fontWeight='bold' title='Afegiu secció Homòfons'>Homòfons</a>, <a href=javascript: id=necparonbutton onclick=document.getElementById('necparonspan').style.display='';necparon=document.getElementById('necparoninput').value;necfunction();this.style.fontWeight='bold' title='Afegiu secció Parònims'>Parònims</a>, <a href=javascript: id=necetymbutton onclick=document.getElementById('necetymspan').style.display='';necetym=document.getElementById('necetyminput').value;necfunction();this.style.fontWeight='bold' title='Afegiu secció Etimologia'>Etimologia</a>, <a href=javascript: id=necanagbutton onclick=document.getElementById('necanagspan').style.display='';necanag=document.getElementById('necanaginput').value;necfunction();this.style.fontWeight='bold' title='Afegiu secció Anagrames'>Anagrames</a>. <span id='necetymspan' style='display:none'><br>Etimologia: <a href=javascript: onclick=necetym=undefined;document.getElementById('necetymspan').style.display='none';necfunction();document.getElementById('necetymbutton').style.fontWeight='' title='Esborra secció Etimologia'>(esborra)</a><br><textarea id=necetyminput onKeyUp=necetym=this.value;necfunction()></textarea></span><span id='nechomofspan' style='display:none'><br>Homòfons: <a href=javascript: onclick=nechomof=undefined;document.getElementById('nechomofspan').style.display='none';necfunction();document.getElementById('nechomofbutton').style.fontWeight='' title='Esborra secció Homòfons'>(esborra)</a><br><textarea id=nechomofinput onKeyUp=nechomof=this.value;necfunction()></textarea></span><span id='necparonspan' style='display:none'><br>Parònims: <a href=javascript: onclick=necparon=undefined;document.getElementById('necparonspan').style.display='none';necfunction();document.getElementById('necparonbutton').style.fontWeight='' title='Esborra secció Parònims'>(esborra)</a><br><textarea id=necparoninput onKeyUp=necparon=this.value;necfunction()></textarea></span><span id=necpronspan style='display:none'><br>Pronúncia: <a href=javascript: onclick=necpron=undefined;document.getElementById('necpronspan').style.display='none';necfunction();document.getElementById('necpronbutton').style.fontWeight='' title='Esborra secció Pronúncia'>(esborra)</a><br><textarea id=necproninput onKeyUp=necpron=this.value;necfunction()></textarea></span><span id=necanagspan style='display:none'><br>Anagrames: <a href=javascript: onclick=necanag=undefined;document.getElementById('necanagspan').style.display='none';necfunction();document.getElementById('necanagbutton').style.fontWeight='' title='Esborra secció Anagrama'>(esborra)</a><br><textarea id=necanaginput onKeyUp=necanag=this.value;necfunction()></textarea></span><div style='float:right;'><a href=/wiki/User_talk:Aleator/novaentrada.js>Suggeriments i errors</a> — <a href=/wiki/Viccionari:Llibre_d'estil>Llibre d'estil</a></div>" document.getElementById("editform").insertBefore(document.getElementById("necblahbeta"),document.getElementById("editform").firstChild) document.getElementById("necblahbeta").innerHTML=x } function AFI() { var wI=document.getElementById('necinput').value; var wT = " (" + wgTitle + ")"; var wP = wgTitle; if(wI=="ca" || wI=="es") { wP=wP.replace('é','e');wP=wP.replace('í','i');wP=wP.replace('ó','o');wP=wP.replace('ú','u');wP=wP.replace('d','ð');wP=wP.replace('ga','ɣa');wP=wP.replace('go','ɣo');wP=wP.replace('gue','ɣe');wP=wP.replace('gui','ɣi');wP=wP.replace('que','ke');wP=wP.replace('qui','ki');wP=wP.replace('gu','ɣu');wP=wP.replace('ll','ʎ');wP=wP.replace('r','ɾ');wP=wP.replace('v','b');wP=wP.replace('nf','ɱf'); } switch(wI) { case "ca": wP=wP.replace('à','a');wP=wP.replace('a','ə');wP=wP.replace('ò','ɔ');wP=wP.replace('e','ə');wP=wP.replace('è','ɛ');wP=wP.replace('ç','s');wP=wP.replace('ce','se');wP=wP.replace('ci','si');wP=wP.replace('ge','ʒe');wP=wP.replace('gi','ʒi');wP=wP.replace('ny','ɲ');wP=wP.replace('tj','dʒ͡');wP=wP.replace('tg','dʒ͡');wP=wP.replace('tx','tʃ͡');wP=wP.replace('j','ʒ');wP=wP.replace('tz','dz͡');wP=wP.replace('x','ʃ');wP=wP.replace('bl','bbl');wP=wP.replace('l·l','ɫɫ');break; case "es": wP=wP.replace('á','a');wP=wP.replace('ch','tʃ͡');wP=wP.replace('ce','θe');wP=wP.replace('ci','θi');wP=wP.replace('x','ks');wP=wP.replace('ge','xe');wP=wP.replace('gi','xi');wP=wP.replace('j','x');wP=wP.replace('ion','jon');wP=wP.replace('ñ','ɲ');wP=wP.replace('y','ʝ');wP=wP.replace('z','θ');break; case "hi": case "mr": case "sa": wP=Deva2AFI(wP,wI); wT=Deva2IAST(wT); break; default: break; } if(wI=="ca" || wI=="es") {wP=wP.replace('c','k');} wP="/"+wP+"/"; if(wI=="hi" || wI=="mr" || wI=="sa") {wP=wP+wT;} document.getElementById('necproninput').value = wP; } function necfunction() { var k=""; document.getElementById("wpSummary").value="nou"; var ISO=document.getElementById('necinput').value; if(necdata['pos2']!="Símbol") { k+="== {"+"{-"+ISO+"-}} ==\n"; //== {{-ca-}} == } if(necpron!=undefined) { if(necpron.length>0) {k+="{"+"{-pronafi-}} {"+"{pron|"+ISO+"|"+necpron+"}}\n";} } if(nechomof!=undefined) { if(nechomof.length>0) {k+="{"+"{homòfons}} "+nechomof+"\n";} } if(necparon!=undefined) { if(necparon.length>0) {k+="{"+"{parònims}} "+necparon+"\n";} } if(necetym!=undefined) { if(necetym.length>0) {k+="{"+"{-etim-}} "+necetym+"\n";} } if(necanag!=undefined) { if(necanag.length>0) {k+="{"+"{anagrama}} "+necanag+"\n";} } if(!neccode){neccode='';} if(neccode!='' && necinfls[neccode] && necinfls[neccode][necdata['pos']] && necinfls[neccode][necdata['pos']][2]) { if(necinfls[neccode][necdata['pos']][0]!=undefined) {k+=necinfls[neccode][necdata['pos']][0];} var x=necinfls[neccode][necdata['pos']]; for (z in x) { if(z<=1) {continue;} var zz=neccode+"-"+necdata['pos']+z; for (y in x[z][2]) { //cerca inflexions if(necdata[zz]==x[z][2][y][0]) {k+=x[z][2][y][1];break;}//clicat if(x[z][2][y][0]=="input" && necfunction7(x[z][2],necdata[zz])==false) {k+=x[z][2][y][2]+necdata[zz];}//inputbox } } if(necinfls[neccode][necdata['pos']][1]!=undefined) { k+=necinfls[neccode][necdata['pos']][1]; } } else { //no hi ha idioma-categoria específic var wC="?"; switch(necdata['pos2']) { case "Adjectiu": wC="adj";break; case "Adverbi": wC="adv";break; case "Article": wC="art";break; case "Conjunció": wC="conj";break; case "Interjecció": wC="interj";break; case "Locucions": wC="loc";break; case "Forma verbal": wC="formaverbal";break; default: wC=necdata['pos2'].toLowerCase(); break; } if(wC!="símbol") {k+="{"+"{-"+wC+"-|"+ISO+"}}";} else {k+="== {"+"{-"+wC+"-}} ==";} if(ISO != "hi" && ISO != "mr" && ISO != "sa") {k+=wS;} } for (i in necdefs) {//Accepcions var Acc=necdefs[i][0]; if( (k.indexOf('|plural}}') != -1) || (k.indexOf('|Nombre=plural}}') != -1)) { if(Acc.indexOf(' ') != -1) {k+="\n#"+Acc+".";} else { if(ISO != "ca") { k+="\n#Plural de {"+"{e|"+wgTitle.substr(0,wgTitle.length-1)+"|"+ISO+"}} ([["+Acc+"]])."; } else {k+="\n#Plural de {"+"{e|"+Acc+"}}.";} } } else { if(necdata['pos2']=="Adjectiu" && (k.indexOf('|f|') != -1 || k.indexOf('|f}') != -1)) {k+="\n#Femení de {"+"{e|"+Acc+"|"+ISO+"}}.";} else { if(ISO != "ca") { if(Acc.indexOf(' ') != -1) {k+="\n#"+Acc+".";} else { if(k.indexOf('nodot=1') != -1) {//formaverbal k+=" ({"+"{e|"+Acc+"}})."; } else { if(ISO == "hi" || ISO == "mr" || ISO == "sa") {k+="[["+Acc+"#ca|"+Acc+"]].";} else {k+="\n#{"+"{e|"+Acc+"}}.";} } } } else {k+="\n#"+Acc;} } } var wW="|"+wgTitle; wW=wW.replace('à','|à|');wW=wW.replace('è','|è|');wW=wW.replace('é','|é|');wW=wW.replace('í','|í|');wW=wW.replace('ï','|ï|');wW=wW.replace('ó','|ó|');wW=wW.replace('ò','|ò|');wW=wW.replace('ú','|ú|');wW=wW.replace('ü','|ü|');wW=wW.replace('ç','|ç|');wW=wW.replace('l·l','|l|l|');wW=wW.replace('||','|'); var wR=""; for(l in necdefs[i][3]) {//Refs. if(necdefs[i][3][l][0].length>6) { wR=necdefs[i][3][l][0]; wR=wR.replace('{'+'{diec}}','<ref name="diec">{'+'{diec'+wW+'}}</ref>'); wR=wR.replace('{'+'{grec}}','<ref name="grec">{'+'{grec'+wW+'}}</ref>'); wR=wR.replace('{'+'{dcvb}}','<ref name="dcvb">{'+'{dcvb}}</ref>'); wR=wR.replace('{'+'{CCLFI}}','<ref name="CCLFI">{'+'{R:CCLFI 1839}}</ref>'); wR=wR.replace('{'+'{DCM}}','<ref name="DCM">{'+'{R:DMC 1840}}</ref>'); wR=wR.replace('{'+'{DLCCCL1}}','<ref name="DLCCCL1">{'+'{R:DLCCCL-1}}</ref>'); wR=wR.replace('{'+'{DLCCCL2}}','<ref name="DLCCCL2">{'+'{R:DLCCCL 1840}}</ref>'); wR=wR.replace('{'+'{Platts}}','<ref name="Platts">{'+'{R:Platts 1884}}</ref>'); wR=wR.replace('{'+'{Vaze}}','<ref>{'+'{R:Vaze 1911}}</ref>'); if(k.indexOf('"diec">') != -1) wR=wR.replace('<ref name="diec">{'+'{diec}}</ref>','<ref name="diec"/>'); if(k.indexOf('"grec">') != -1) wR=wR.replace('<ref name="grec">{'+'{grec}}</ref>','<ref name="grec"/>'); if(k.indexOf('"dcvb">') != -1) wR=wR.replace('<ref name="dcvb">{'+'{dcvb}}</ref>','<ref name="dcvb"/>'); if(k.indexOf('"CCLFI">') != -1) wR=wR.replace('<ref name="CCLFI">{'+'{R:CCLFI 1839}}</ref>','<ref name="CCLFI"/>'); if(k.indexOf('"DCM">') != -1) wR=wR.replace('<ref name="DCM">{'+'{R:DMC 1840}}</ref>','<ref name="DCM"/>'); if(k.indexOf('"DLCCCL1">') != -1) wR=wR.replace('<ref name="DLCCCL1">{'+'{R:DLCCCL-1}}</ref>','<ref name="DLCCCL1"/>'); if(k.indexOf('"DLCCCL2">') != -1) wR=wR.replace('<ref name="DLCCCL2">{'+'{R:DLCCCL 1840}}</ref>','<ref name="DLCCCL2"/>'); if(k.indexOf('"Platts">') != -1) wR=wR.replace('<ref name="Platts">{'+'{R:Platts 1884}}</ref>','<ref name="Platts"/>'); k+=wR; } } for(l in necdefs[i][1]) {//Exemple k+="\n#:\'\'"+necdefs[i][1][l][0].replace(new RegExp("("+wgTitle+")","ig"),"'''$1'''")+"''"; if(neccode!="ca" && necdefs[i][1][l][2]){k+=" (''"+necdefs[i][1][l][2]+"'')";} //Traducció } for(l in necdefs[i][2]) {//Citació bibliogràfica k+="\n#:''"; k+=necdefs[i][2][l][5].replace(new RegExp("("+wgTitle+")","ig"),"'''$1'''"); if(neccode!="ca"){k+=" (''"+necdefs[i][2][l][6]+"'')";} if(necdefs[i][2][l][1]) {k+="'' ({"+"{Versaleta|"+necdefs[i][2][l][1]+"}}";}//autor if(necdefs[i][2][l][2]) {k+=": ''"+necdefs[i][2][l][2]+"''";}//obra if(necdefs[i][2][l][3]) {k+=", "+necdefs[i][2][l][3];}//edit. if(necdefs[i][2][l][0]) {k+=", "+necdefs[i][2][l][0];}//any if(necdefs[i][2][l][4]) {k+=", p."+necdefs[i][2][l][4];}//pàgs. k+=")."; } } k+="\n"; for(i in necpost[3]) {k+="\n====Declinació====\n"+necpost[3][i]+"\n";} var HH=0;//hi ha? for(i in necpost[0]) { //Sinònims if(HH==0) {k+="\n{"+"{-sin-}}";HH=1;} if(necpost[0][i][0]) {k+="\n*" + necpost[0][i][0] + ": ";} else {k+="\n";} for(u in necpost[0][i]) { if(u!=0){ //concatenar sinònims if(u!=1){k+=", ";} if(ISO=="ca") {k+= "{" + "{e|" +necpost[0][i][u] + "|" + ISO + "}}";} else {k+= "{" + "{e|" +necpost[0][i][u] + "}}";} } } k+="\n"; } if(ISO=="ca") { //traduccions if(necpost[1]) { HH=0; for(i in necpost[1]) { if(HH==0) {k+="\n{"+"{-trad-}}\n";k+="{"+"{inici}}";HH=1;} k+="\n*{"+"{"+necpost[1][i][0]+"}}: "; for(u in necpost[1][i]) { if(u!=0){ //concatenar trads if(u!=1){k+=", ";} k+="{"+"{trad|"+necpost[1][i][0]+"|"+necpost[1][i][u]+"}}"; } } } if(HH==1) {k+="\n{"+"{final}}\n";} } } if(k.indexOf('<ref')!=-1) {k+="==Referències==\n<references />\n";} var wM=wgTitle;HH=0;//{{ordre}} for(i=0;i<wM.length;i++) { var wL = wM.substr(i,1); switch(wL) { case "à": case "á": case "è": case "é": case "í": case "ó": case "ò": case "ú": case "ç": HH=1; break; default:break; } } if(HH>0) { wM=wM.replace('á','a');wM=wM.replace('à','a');wM=wM.replace('é','e');wM=wM.replace('è','e');wM=wM.replace('í','i');wM=wM.replace('ó','o');wM=wM.replace('ò','o');wM=wM.replace('ú','u');wM=wM.replace('ç','c');wM=wM.replace('l·l','ll'); k+="\n{{ordre|"+wM+"}}\n"; } for(i in necpost[2]) {k+="\n["+"[Categoria:"+necpost[2][i]+"]]";} if(ISO=="en") {k += "\n[[en:"+wgTitle+"]]\n";} document.editform.wpTextbox1.value=k; } function necCleanLangCode(lang) {//converteix a codi ISO var key = lang.toLowerCase().replace(' ',''); var dict = {aar:"aa",afar:"aa",abk:"ab",afr:"af",afrikaans:"af",aka:"ak",akan:"ak",amh:"am",amharic:"am",ara:"ar",àrab:"ar",arg:"an",aragonès:"an",asm:"as",ava:"av",avaric:"av",ave:"ae",avestan:"ae",aym:"ay",aymara:"ay",aze:"az",bak:"ba",bashkir:"ba",bam:"bm",bambara:"bm",bel:"be",bielorús:"be",ben:"bn",bengali:"bn",bis:"bi",bislama:"bi",bod:"bo",tibetà:"bo",bos:"bs",bosni:"bs",bre:"br",bretó:"br",bul:"bg",búlgar:"bg",cat:"ca",catala:"ca",català:"ca",ces:"cs",txec:"cs",cha:"ch",chamorro:"ch",che:"ce",txetxè:"ce",chu:"cu",chv:"cv",cor:"kw",còrnic:"kw",cos:"co",cors:"co",cre:"cr",cree:"cr",cym:"cy",welsh:"cy",dan:"da",danès:"da",deu:"de",alemany:"de",div:"dv",dhivehi:"dv",dzo:"dz",dzongkha:"dz",ell:"el",grec:"el",eng:"en",anglès:"en",epo:"eo",esperanto:"eo",est:"et",estoni:"et",eus:"eu",basc:"eu",ewe:"ee",fao:"fo",faroese:"fo",fas:"fa",persa:"fa",fij:"fj",fin:"fi",finès:"fi",fra:"fr",francés:"fr",fry:"fy",ful:"ff",fulah:"ff",gla:"gd",gle:"ga",irlandès:"ga",glg:"gl",gallec:"gl",glv:"gv",manx:"gv",grn:"gn",guaraní:"gn",guj:"gu",gujarati:"gu",hat:"ht",haitià:"ht",hau:"ha",hausa:"ha",heb:"he",hebreu:"he",her:"hz",herero:"hz",hin:"hi",hindi:"hi",hmo:"ho",hirimotu:"ho",hrv:"hr",croat:"hr",hun:"hu",hongarès:"hu",hye:"hy",armeni:"hy",ibo:"ig",igbo:"ig",ido:"io",iii:"ii",iku:"iu",inuktitut:"iu",ile:"ie",ina:"ia",interlingua:"ia",ind:"id",indonesi:"id",ipk:"ik",inupiaq:"ik",isl:"is",islandès:"is",ita:"it",italià:"it",jav:"jv",javanès:"jv",jpn:"ja",japonès:"ja",kal:"kl",kan:"kn",kannada:"kn",kas:"ks",kashmiri:"ks",kat:"ka",georgià:"ka",kau:"kr",kanuri:"kr",kaz:"kk",kazakh:"kk",khm:"km",centralkhmer:"km",kik:"ki",kikuyu:"ki",kin:"rw",kir:"ky",kirghiz:"ky",kom:"kv",komi:"kv",kon:"kg",kongo:"kg",kor:"ko",koreà:"ko",kua:"kj",kuanyama:"kj",kur:"ku",kurd:"ku",lao:"lo",lat:"la",llatí:"la",lav:"lv",latvian:"lv",lim:"li",limburguès:"li",lin:"ln",lingala:"ln",lit:"lt",lituani:"lt",ltz:"lb",luxemburguès:"lb",lub:"lu",lubakatanga:"lu",lug:"lg",ganda:"lg",mah:"mh",mal:"ml",malayalam:"ml",mar:"mr",marathi:"mr",mkd:"mk",macedoni:"mk",mlg:"mg",malagasy:"mg",mlt:"mt",mon:"mn",mongol:"mn",mri:"mi",maori:"mi",msa:"ms",malay:"ms",mya:"my",burmese:"my",nau:"na",nauru:"na",nav:"nv",navajo:"nv",nbl:"nr",nde:"nd",ndo:"ng",ndonga:"ng",nep:"ne",nepali:"ne",nld:"nl",dutch:"nl",nno:"nn",nob:"nb",nor:"no",noruec:"no",nya:"ny",nyanja:"ny",oci:"oc",occità:"oc",oji:"oj",ori:"or",oriya:"or",orm:"om",oromo:"om",oss:"os",pan:"pa",panjabi:"pa",pli:"pi",pali:"pi",pol:"pl",polonès:"pl",por:"pt",portuguès:"pt",pus:"ps",pushto:"ps",que:"qu",quechua:"qu",roh:"rm",romanx:"rm",ron:"ro",romanès:"ro",run:"rn",rundi:"rn",rus:"ru",sag:"sg",san:"sa",sanskrit:"sa",sin:"si",sinhala:"si",slk:"sk",slv:"sl",esloveni:"sl",sme:"se",smo:"sm",sna:"sn",shona:"sn",snd:"sd",sindhi:"sd",som:"so",somali:"so",sot:"st",spa:"es",castella:"es",castellà:"es",espanyol:"es",sqi:"sq",albanès:"sq",srd:"sc",sard:"sc",srp:"sr",serbi:"sr",swahili:"sw",swe:"sv",suec:"sv",tah:"ty",tahitià:"ty",tam:"ta",tamil:"ta",tat:"tt",tatar:"tt",tel:"te",telugu:"te",tgk:"tg",tajik:"tg",tgl:"tl",tagalog:"tl",tha:"th",thai:"th",ton:"to",tonga:"to",tsn:"tn",tswana:"tn",tso:"ts",tuk:"tk",turcman:"tk",tur:"tr",turc:"tr",uig:"ug",uigur:"ug",ukr:"uk",ucrainès:"uk",urd:"ur",urdu:"ur",uzb:"uz",uzbek:"uz",valencià:"ca",ven:"ve",venda:"ve",vie:"vi",vietnamita:"vi",vol:"vo",wln:"wa",walloon:"wa",wol:"wo",wolof:"wo",xho:"xh",xhosa:"xh",yid:"yi",yiddish:"yi",yor:"yo",yoruba:"yo",xinés:"zh",zulú:"zu"} return dict[key]; } function necfunction4() { if(!neccode){neccode='';} if(neccode && necinfls[neccode] && necinfls[neccode][necdata['pos']]!=undefined && necinfls[neccode][necdata['pos']][2]!=undefined) {necfunction5(necinfls[neccode][necdata['pos']]);} else { //ocultar idioma-categoria no específic var xx="<span class=buit></span>"; document.getElementById("necinfls").innerHTML=xx; necfunction(); } } function necfunction5(a) { /* INFLECTION OPTIONS */ var q=""; for(r in a) { if(r<=1) {continue;} var qq=neccode+"-"+necdata['pos']+r; if(necdata[qq]==undefined) { if(a[r][2][0][0]=='input'){necdata[qq]='';} else{necdata[qq]=a[r][2][0][0];} } q+="<br>"+a[r][0]+": "; for(i in a[r][2]) { if(a[r][2][i][0]!='input') { q+="<a href=javascript: id='necinput"+qq+a[r][2][i][0]+"' onclick=\""; if(a[r][2][i][2]) {q+=a[r][2][i][2]+";";} q+="necdata[\'"+qq+"\']=\'"+a[r][2][i][0]+"\';necfunction4();necfunction()\">"+a[r][2][i][0]+"</a>"; if(i!=a[r][2].length-1){q+=", "} } else { q+="<span id='necinput"+qq; if(necfunction7(a[r][2],necdata[qq])==false) {q+=necdata[qq];} q+="'>"+a[r][2][i][1]+"<input type=text value='' id='"; q+=neccode+"-"+necdata['pos']+"-"+r+"-"+i; q+="' onKeyUp="; if(a[r][2][i][4]) {q+=a[r][2][i][4]+";";} q+="necfunction6('"+qq+"','"+neccode+"-"+necdata['pos']+"-"+r+"-"+i+"');"; q+="necfunction() /></span>"; if(i!=a[r][2].length-1){q+=", ";} } } } document.getElementById("necinfls").innerHTML=q; for(r in a) { if(r<=1) {continue;} var qq=neccode+"-"+necdata['pos']+r; document.getElementById('necinput'+qq+necdata[qq]).style.fontWeight='bold'; if(document.getElementById('necinput'+qq+necdata[qq]).childNodes[1]&&necfunction7(a[r][2],necdata[qq])==false) { document.getElementById('necinput'+qq+necdata[qq]).childNodes[1].value=necdata[qq]; }}} function necdefupdate() { //ACCEPCIONS: Exemples, citacions, refs. def=""; for(i in necdefs) { def+="Accepció: <input size=110 type=text value='"+necdefs[i][0]+"' onKeyUp=necdefs["+i+"][0]=this.value;necfunction() />"; if(i>0) {def+="<a href=javascript:necdefs.splice("+i+",1);uNec() title='Esborra aquesta definició'>(–)</a>";} def+="<a href=javascript:necdefs["+i+"][1].push(['','','']);uNec() title='Afegiu exemple'>(+exemple)</a><a href=javascript:necdefs["+i+"][2].push(['','','','','','','']);uNec() title='Afegeix citació'>(+citació)</a><a href=javascript:necdefs["+i+"][3].push(['','','']);uNec() title='Afegiu referència'>(+referència)</a>" for(l in necdefs[i][1]) { //Exemple def+="<br><span style='padding-left:30px;'>Exemple: </span><input type=text size=40 value='"+necdefs[i][1][l][0]+"' onKeyUp=necdefs["+i+"][1]["+l+"][0]=this.value;necfunction() /><a href=javascript:necdefs["+i+"][1].splice("+l+",1);uNec() title='Esborra aquest exemple'>(–)</a>"; if(neccode!="ca") { def+="<br><span style='padding-left:60px;'>Traducció: </span><input type=text size=40 value='"+necdefs[i][1][l][2]+"' onKeyUp=necdefs["+i+"][1]["+l+"][2]=this.value;necfunction() />"; } } for(l in necdefs[i][2]) { //Citacions var x=['Any','Autor','Títol','Editor','Pàgines']; var z=[4,20,20,20,5]; //mides def+="<br><span style='padding-left:30px;'>"; for(y in x) { def+=x[y]+": <input type=text size="+z[y]+" value='"+necdefs[i][2][l][y]+"' onKeyUp=necdefs["+i+"][2]["+l+"]["+y+"]=this.value;necfunction() /> "} def+="</span><br><span style='padding-left:30px;'>Citació: <input type=text size=40 value='"+necdefs[i][2][l][5]+"' onKeyUp=necdefs["+i+"][2]["+l+"][5]=this.value;necfunction() /><a href=javascript:necdefs["+i+"][2].splice("+l+",1);uNec() title='Esborra aquesta citació'>(–)</a>"; if(neccode!="ca") {def+="<br><span style='padding-left:60px;'>Traducció: </span><input type=text size=40 value='"+necdefs[i][2][l][6]+"' onKeyUp=necdefs["+i+"][2]["+l+"][6]=this.value;necfunction() />";} } for(l in necdefs[i][3]) { //Ref. def+="<br><span style='padding-left:30px;'>Refs.: </span><input type=text size=40 value='"+necdefs[i][3][l][0]+"' onKeyUp=necdefs["+i+"][3]["+l+"][0]=this.value;necfunction() />"; if(neccode=="ca") {def+=" DIEC:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{diec}}';uNec() /> GREC:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{grec}}';uNec() /> DCVB:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{dcvb}}';uNec() />";} if(neccode=="hi" || neccode=="ur" || neccode=="sa") {def+=" Platts:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{Platts}}';uNec() />";} if(neccode=="mr") {def+=" Vaze:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{Vaze}}';uNec() />";} if(neccode=="ca" || neccode=="es") { def+=" CCLFI:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{CCLFI}}';uNec() /> DCM:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{DCM}}';uNec() /> DLCCCL1:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{DLCCCL1}}';uNec() /> DLCCCL2:<input type=checkbox onclick=necdefs["+i+"][3]["+l+"][0]+='{{DLCCCL2}}';uNec() />";} def+="<a href=javascript:necdefs["+i+"][3].splice("+l+",1);uNec() title='Esborra ref.'>(–)</a>"; } def+="<br>"; } document.getElementById('necdefs').innerHTML=def; } function necpostbox(q) { if(q!=undefined) { if(q==0) {necpost[q][necpost[q].length]='';}//Sin. else if(q==1) {necpost[q][necpost[q].length]=['',''];}//Trad. else if(q==2) {necpost[q][necpost[q].length]='';}//Cat. else if(q==3) {necpost[q][necpost[q].length]='';}//Decl. } var m=""; for(o=0;o<2;o++) { if(o==0) {//Sin. document.getElementById('necSynonymsbutton').style.fontWeight=''; } else if(o==1) {//Trad. document.getElementById('nectransbutton').style.fontWeight=''; } for(i in necpost[o]) { if(o==1) {//Trad. m+="<span style='padding-left:60px;'>Idioma: <input type=text size=5 value='"+necpost[o][i][0]+"' onKeyUp=necpost["+o+"]["+i+"][0]=this.value;necfunction() /> "+necheadingorder[o]+": "; } else {//Sin. m+="<span style='padding-left:60px;'>Accepció: <input type=text value='"+necpost[o][i][0]+"' onKeyUp=necpost["+o+"]["+i+"][0]=this.value;necfunction() /> "+necheadingorder[o]+": "; } for(u in necpost[o][i]) { if(u!=0){ if(u!=1){m+=", ";} m+="<input type=text size=10 value='"+necpost[o][i][u]+"' onKeyUp=necpost["+o+"]["+i+"]["+u+"]=this.value;necfunction() />"; } } m+="<a href=javascript:necpost["+o+"]["+i+"].push('');necpostbox();necfunction() title='Add "+necheadingorder[o].substr(0,necheadingorder[o].length-1).toLowerCase()+"'>(+)</a>"; if(necpost[o][i].length>2) { m+="<a href=javascript:necpost["+o+"]["+i+"].splice("+(necpost[o][i].length-1)+",1);necpostbox();necfunction() title='Esborra "+necheadingorder[o].substr(0,necheadingorder[o].length-1).toLowerCase()+"'>(–)</a>"; } m+="<a href=javascript:necpost["+o+"].splice("+i+",1);necpostbox();necfunction() title='Elimina secció'>(elimina secció)</a><br>"; } } if(necpost[2][0]!=undefined) { for(i in necpost[2]) { m+="<span style='padding-left:30px;'>Categoria:<input type=text value='"+necpost[2][i]+"' onKeyUp=necpost[2]["+i+"]=this.value;necfunction() /><a href=javascript:necpost[2].splice("+i+",1);necpostbox();necfunction() title='Elimina categoria'>(–)</a>"; if(i==0) { m+="<a href=javascript:necpost[2].push('');necpostbox();necfunction() title='Afegir nova categoria'>(+nova categoria)</a>"; } m+="</span><br>"; } } if(necpost[3][0]!=undefined) { for(i in necpost[3]) { m+="<span style='padding-left:30px;'>Declinació:<input type=text value='"+necpost[3][i]+"' onKeyUp=necpost[3]["+i+"]=this.value;necfunction() /><a href=javascript:necpost[3].splice("+i+",1);necpostbox();necfunction() title='Elimina'>(–)</a>"; if(i==0) { m+="<a href=javascript:necpost[3].push('');necpostbox();necfunction() title='Afegir'>(+)</a>"; } m+="</span><br>"; } } document.getElementById('necpostbox').innerHTML=m; } function necfunction6(cc,dd) {document.getElementById('necinput'+cc+necdata[cc]).style.fontWeight='';necdata[cc]=document.getElementById(dd).value;document.getElementById(dd).parentNode.setAttribute('ID','necinput'+cc+document.getElementById(dd).value);document.getElementById('necinput'+cc+necdata[cc]).style.fontWeight='bold';} function necfunction7(qw,er) {var qwe=false;for(ty in qw) {if(er==qw[ty][0]){qwe=true}}return qwe;} function uNec() {necdefupdate();necfunction();} function necload() { var PP=document.getElementById('ca-nstab-main'); if(PP) { if(PP.firstChild) {//!! if(document.getElementById('necblahbeta')) { necfunction2();uNec();necfunction4();necfunction(); } }}} addOnloadHook(necload); All content in the above text box is licensed under the Creative Commons Attribution-ShareAlike license Version 4 and was originally sourced from https://ca.wiktionary.org/w/index.php?diff=prev&oldid=254171.
![]() ![]() This site is not affiliated with or endorsed in any way by the Wikimedia Foundation or any of its affiliates. In fact, we fucking despise them.
|