Потребител:V111P/monobook.js
от Уикипедия, свободната енциклопедия
Бележка: След съхранението е необходимо да изтриете кеша на браузъра, за да видите промените: Mozilla / Firefox / Safari: натиснете бутона Shift и щракнете върху Презареждане (Reload), или изберете клавишната комбинация Ctrl-Shift-R (Cmd-Shift-R за Apple Mac); IE: натиснете Ctrl и щракнете върху Refresh, или клавишната комбинация CTRL-F5; Konqueror: щракнете върху Презареждане или натиснете F5; Opera: вероятно е необходимо да изчистите кеша през менюто Tools→Preferences.
customMiscButtons[customMiscButtons.length] = ["replaceSelection('cyrLat')", "Кирилица към латиница", "Lat"]; customMiscButtons[customMiscButtons.length] = ["replaceSelection('latCyr')", "Латиница към кирилица", "Кир"]; cyr = new Array('щ', 'ц', 'ч', 'ш', 'ъ', 'ь','ю', 'я', 'Щ', 'Ц', 'Ч', 'Ш', 'Ъ', 'Ь','Ю', 'Я', 'а','б','в','г','д', 'е', 'ж', 'з', 'и', 'й','к', 'л','м','н','о','п','р','с','т','у','ф','х', 'А','Б','В','Г','Д', 'Е', 'Ж', 'З', 'И', 'Й','К', 'Л','М','Н','О','П','Р','С','Т','У','Ф','Х'); lat = new Array('sht','ts','ch','sh','q', 'w','yu','ya', 'Sht','Ts','Ch','Sh','Q', 'W','Yu','Ya', 'a','b','v','g','d', 'e', 'j', 'z', 'i', 'y','k', 'l','m','n','o','p','r','s','t','u','f','h', 'A','B','V','G','D', 'E', 'J', 'Z', 'I', 'Y','K', 'L','M','N','O','P','R','S','T','U','F','H'); /** Import module ************************************************************* * * Description: Includes a raw wiki page as javascript or CSS, * used for including user made modules. * From: [[:en:MediaWiki:Common.js]] * Maintainers: [[:en:User:AzaToth]] */ importedScripts = {}; // object keeping track of included scripts, so a script ain't included twice function importScript( page ) { if( importedScripts[page] ) { return; } importedScripts[page] = true; var url = wgScriptPath + '/index.php?title=' + encodeURIComponent( page.replace( / /g, '_' ) ) + '&action=raw&ctype=text/javascript'; var scriptElem = document.createElement( 'script' ); scriptElem.setAttribute( 'src' , url ); scriptElem.setAttribute( 'type' , 'text/javascript' ); document.getElementsByTagName( 'head' )[0].appendChild( scriptElem ); } function importStylesheet( page ) { var sheet = '@import "' + wgScriptPath + '/index.php?title=' + encodeURIComponent( page.replace( / /g, '_' ) ) + '&action=raw&ctype=text/css";' var styleElem = document.createElement( 'style' ); styleElem.setAttribute( 'type' , 'text/css' ); styleElem.appendChild( document.createTextNode( sheet ) ); document.getElementsByTagName( 'head' )[0].appendChild( styleElem ); } importScript("Потребител:V111P/replaceSelection.js"); importScript("Потребител:V111P/cyr.js");