User:HitomiAkane/ar2arz.js

var addToolbarButtonsUrl = '//en.wikipedia.org/w/index.php?title=' + 'User:V111P/js/addToolbarButtons.js&action=raw&ctype=text/javascript'; // Backlink: User:V111P/js/addToolbarButtons.js

var myToolbarButton = { id: 'ar2arzButton', callback: function {alert('hi');}, // you can remove this callback property, remember that it's not required iconUrl: '//upload.wikimedia.org/wikipedia/commons/' + 'thumb/f/fb/Template_icon.svg/22px-Template_icon.svg.png', iconUrlClassic: '//upload.wikimedia.org/wikipedia/commons/9/97/Template_button.png' };

if (mw.libs.addToolbarButtons) mw.libs.addToolbarButtons(myToolbarButton); else { var tbs = window.toolbarButtonsToAdd = window.toolbarButtonsToAdd || []; tbs.push(myToolbarButton); mw.loader.load(addToolbarButtonsUrl); }