Poznámka: Po uložení musíte vyprázdnit mezipaměť vašeho prohlížeče, jinak změny neuvidíte.

//<nowiki>
/** Tlačidlá */
mw.loader.using('mediawiki.action.edit', function () {
	

 
var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/2/23/Button_code.png',
                       speedTip: 'code',
                       tagOpen: '<code>',
                       tagClose: '</code>',
                       sampleText: 'text'
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/3/3c/Button_pre.png',
                       speedTip: 'přeformátovaný text',
                       tagOpen: '<pre>',
                       tagClose: '</pre>',
                       sampleText: 'přeformátovaný text'
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);
 
var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/a/a5/Buttonexperimenty.png',
                       speedTip: 'experimenty',
                       tagOpen: '\x7b\x7bexperimenty}} \x7E\x7E\x7E\x7E',
                       tagClose: '',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);
 
var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/1/16/Buttonexperimenty2.png',
                       speedTip: 'experimenty2',
                       tagOpen: '\x7b\x7bexperimenty2}} \x7E\x7E\x7E\x7E',
                       tagClose: '',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);
 
var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/7/72/Button_copy_vio_plagio.png',
                       speedTip: 'Copyvio',
                       tagOpen: '\x7b\x7bcopyvio|url=',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/3/37/Button_no_neutral.png',
                       speedTip: 'neutralita',
                       tagOpen: '\x7b\x7bneutralita',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/a/a4/Spam1.png',
                       speedTip: 'Reklama',
                       tagOpen: '\x7b\x7bReklama',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/e/eb/Button_plantilla.png',
                       speedTip: 'Šablona',
                       tagOpen: '\x7b\x7bŠablona|',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/7/71/TableCell.png',
                       speedTip: 'Zvislá čára',
                       tagOpen: '|',
                       tagClose: '',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/0/02/Button_fuente_primaria.png',
                       speedTip: 'bez citace',
                       tagOpen: '\x7b\x7bbez citace',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/3/33/Button_unreferenced.png',
                       speedTip: 'bez zdroje',
                       tagOpen: '\x7b\x7bbez zdroje',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/4/4f/Button_sig_(zh).png',
                       speedTip: 'Překlad',
                       tagOpen: '* \x7b\x7bPřeklad|en|to|00',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/0/09/Warncreate3.png',
                       speedTip: 'na revizi',
                       tagOpen: '\x7b\x7bna revizi',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/6/6c/Button_commons.png',
                       speedTip: 'Commons',
                       tagOpen: '\x7b\x7bprojekt|commons=Category:',
                       tagClose: '}}',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/9/91/Button_cite_web.png',
                       speedTip: 'Citace elektronické monografie',
                       tagOpen: '<ref>\x7b\x7bCitace elektronické monografie\n | příjmení = \n | jméno = \n | odkaz na autora = \n | vydavatel = \n | titul = \n | url = \n | datum vydání = 2012-00-0 \n | dátum přístupu = ' + (y = new Date().getFullYear ()) + '-' + (m = new Date ().getMonth () + 1) + '-' + (d = new Date ().getDate ()) + '\n | místo = \n | jazyk = \n}}</ref>',
                       tagClose: '',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
                       imageFile: '//upload.wikimedia.org/wikipedia/commons/e/ef/Button_cite_book.png',
                       speedTip: 'Citace monografie',
                       tagOpen: '<ref>\x7b\x7bCitace monografie\n | příjmení = \n | jméno = \n | odkaz na autora = \n | titul = \n | vydavatel = \n | místo = \n | rok = \n | isbn = \n | strany = \n | počet stran = \n | url = \n | jazyk = \n}}</ref>',
                       tagClose: '',
                       sampleText: ''
        };
        mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);

var button = { id: 'button-comment',
    imageFile: '//upload.wikimedia.org/wikipedia/commons/5/59/Button_sekcje.png',
    speedTip: 'Koncové sekce (Reference, Související články, Externí odkazy, Zdroj)',
    tagOpen: '== Reference =='+
'\n <references />', 
    'tagClose':
'\n'+
'\n== Související články =='+   
'\n* [[]]'+
'\n'+
'\n'+
'\n== Externí odkazy =='+
'\n* []'+
'\n'+
'\n== Zdroj =='+
'\n* \x7b\x7bPřeklad|en|to|00}}'+
'\n',
    sampleText: ''
      };
      mw.toolbar.addButton(button.imageFile, button.speedTip, button.tagOpen, button.tagClose, button.sampleText, button.id, button.id);
 
});


/*
=== Odkaz na pieskovisko ===
*/
 
var disableSandboxLink = 0;	// ustawienie tego na 1 lub true w swoim monobook.js pozwoli wyłączyć tę funkcjonalność
 
$(function()
{
	if (wgUserName != null && disableSandboxLink == 0)
	{
		var caption = 'P1'
		if (wgUserLanguage != 'sk')
			caption = 'My sandbox';
 
		mw.util.addPortletLink('p-personal', mw.config.get('wgServer') + mw.config.get('wgScript') + '?title=Special:Mypage/Pieskovisko', caption, 'pt-sandbox', caption, '', document.getElementById('pt-preferences'));
	}
});
 
 
var disableSandboxLink = 0;	// ustawienie tego na 1 lub true w swoim monobook.js pozwoli wyłączyć tę funkcjonalność
 
$(function()
{
	if (wgUserName != null && disableSandboxLink == 0)
	{
		var caption = 'P2'
		if (wgUserLanguage != 'sk')
			caption = 'My sandbox';
 
		mw.util.addPortletLink('p-personal', mw.config.get('wgServer') + mw.config.get('wgScript') + '?title=Special:Mypage/Pieskovisko 2', caption, 'pt-sandbox', caption, '', document.getElementById('pt-preferences'));
	}
});
 
var disableSandboxLink = 0;	// ustawienie tego na 1 lub true w swoim monobook.js pozwoli wyłączyć tę funkcjonalność
 
$(function()
{
	if (wgUserName != null && disableSandboxLink == 0)
	{
		var caption = 'P3'
		if (wgUserLanguage != 'sk')
			caption = 'My sandbox';
 
		mw.util.addPortletLink('p-personal', mw.config.get('wgServer') + mw.config.get('wgScript') + '?title=Special:Mypage/Pieskovisko 3', caption, 'pt-sandbox', caption, '', document.getElementById('pt-preferences'));
	}
});

function loadScript(url)
{
   var e = document.createElement("script");
   e.src = url;
   e.type="text/javascript";
   document.getElementsByTagName("head")[0].appendChild(e);
}
 
loadScript("http://cs.wikipedia.org/w/index.php?title=Wikipedista:Mormegil/tools.js&action=raw&ctype=text/javascript&dontcountme=s");
 
$(function() { addSummaryToolbar(["drobná úprava ", "na úpravu ", "wikify", "", "doplnenie ", "nový článok ", "oprava ", "", "experimenty", "fix", "commons", "", "presmerovanie  ",]); });
$(function() { addFindAndReplaceToolbar() });


function vitajte(){
    var reg = confirm("Reg?");
    document.editform.wpSummary.value = 'Vitajte/Welcome ';
    var txt = document.editform.wpTextbox1;
    if(txt.value.length > 0) txt.value += '\n';
    if(reg)
        txt.value += '{{Vitajte|redaktor=Magy357|reg=regáno}}';
    else
        txt.value += '{{Vitajte|redaktor=Magy357|reg=regnie}}';
    txt.focus();
}

function experimenty(){
    var dva = confirm("Druhýkrát?");
    var txt = document.editform.wpTextbox1;
    if(txt.value.length > 0) txt.value += '\n';
    if (dva) {
      txt.value += '{{experimenty2}}\n--~~'+'~~';
      document.editform.wpSummary.value = '{{experimenty2}}';
    } else {
      txt.value += '{{experimenty}}\n--~~'+'~~';
      document.editform.wpSummary.value = '{{experimenty}}';
    }
    txt.focus();
}

function vandalizmus(){
    document.editform.wpSummary.value = '{{vandalizmus}}';
    var txt = document.editform.wpTextbox1;
    if(txt.value.length > 0) txt.value += '\n';
    txt.value += '{{vandalizmus}}\n--~~'+'~~';
    txt.focus();
}

function zaregistrujse(){
    document.editform.wpSummary.value = '{{zaregistruj se}}';
    var txt = document.editform.wpTextbox1;
    if(txt.value.length > 0) txt.value += '\n';
    txt.value += '{{zaregistruj se}}\n--~~'+'~~';
    txt.focus();
}
  
function addlilink(tabs, url, name, id){
    var na = document.createElement('a');
    na.href = url;
    na.id = id;
    na.appendChild(document.createTextNode(name));
    var li = document.createElement('li');
    li.appendChild(na);
    tabs.appendChild(li);
    return li;
}

function morelinks(){
    var tabs = document.getElementById('p-cactions').getElementsByTagName('ul')[0];
    if(document.title.indexOf("Úprava stránky Diskusia s redaktorom")
== 0){
        addlilink(tabs, 'javascript:vitajte()', 'vitajte', '');
        addlilink(tabs, 'javascript:experimenty()', 'exp', '');
        addlilink(tabs, 'javascript:vandalizmus()', 'vandal', '');
        addlilink(tabs, 'javascript:zaregistrujse()', 'reg', '');
    }
}

function myLoadFuncs(){
if (!window.ta) window.ta = {};

//    addEditSection0();
    morelinks();
}

if (window.addEventListener)
window.addEventListener("load",myLoadFuncs,false);
else if (window.attachEvent)
window.attachEvent("onload",myLoadFuncs);
else {
    window._old_ABCD_onload = window.onload;
    window.onload = function(){
        window._old_ABCD_onload();
        myLoadFuncs();
    }
}

 // [[:en:User:Lupin/popups.js]] - please include this line, prosím nemažte tento riadok
 // [[Redaktor:jsimlo/popups.js]] - please include this line, prosím nemažte tento riadok
 
 document.write('<script type="text/javascript" src="' 
   + 'http://sk.wikipedia.org/w/index.php?title=User:jsimlo/popups.js' 
   + '&action=raw&ctype=text/javascript&dontcountme=s"></script>');
//</nowiki>