User:Karl Dickman/standard.js
From Wikipedia, the free encyclopedia
Note: After saving, you have to bypass your browser's cache to see the changes. Firefox/Mozilla/Safari: hold down Shift while clicking Reload (or press Ctrl-Shift-R), Internet Explorer: press Ctrl-F5, Opera/Konqueror: press F5.
//{{User:Karl Dickman/Subpages}} //Create 'importScript' function: function importScript(s) { document.write('<script type="text/javascript" src="' + 'http://en.wikipedia.org/w/index.php?title=User:' + s + '.js&action=raw&ctype=text/javascript&dontcountme=s"></script>'); } //==XEB== myButtons={ 'Mm':['http://upload.wikimedia.org/wikipedia/commons/f/fd/Button_blockquote.png','Insert block of quoted text','<blockquote>','</blockquote>','Block quote'], 'Ba':['http://upload.wikimedia.org/wikipedia/commons/1/13/Button_enter.png','Line break','<br clear="','"/>','all'] }; rmEditButtons=['all']; XEBOrder="0,1,U,S,I1,I2,J1,J2,2,P1,3,4,A,5,AI,G,6,7,8,9,FS,10,V,H,O,P,T,Z,TL,Y1,Y2,K,B,D,C,D1,F,Q,W,X,L,R1,R2,R3,R4,N"; importScript('MarkS/extraeditbuttons');//[[User:MarkS/extraeditbuttons.js]] //===Additional buttons=== //importScript('Karl Dickman/tablebutton'); //importScript('Karl Dickman/airbuttons'); //==Interiot's javascript edit counter== if (document.title.indexOf('User:Interiot/Tool2/code.js') != -1) { document.write('<script type="text/javascript" src="' + 'http://en.wikipedia.org/w/index.php?title=User:Interiot/Tool2/code.js' + '&action=raw&ctype=text/javascript&dontcountme=s"></script>'); } // Script from [[User:Lupin/editcount.js]] importScript('Lupin/editcount'); popupEditCounterTool='custom'; popupEditCounterUrl='http://en.wikipedia.org/wiki/User:$1?ectarget=$1'; // [[User:Lupin/popups.js]] - please include this line importScript('Lupin/popupsdev'); popupDelay=0.2; popupAdminLinks=true; popupShortcutKeys=true; popupDragging=true; popupFixRedirs=true; popupFixDabs=true; popupMaxPreviewSentences=10; popupMaxPreviewCharacters=1500; //function to add counter tool link importScript('Userscripts/Editcount link/source');//[[User:Userscripts/Editcount link/source.js]] //if(skin=="standard") { //function to handle dates: importScript('Karl Dickman/dates');//[[User:Karl Dickman/dates.js]] //function to handle units: importScript('Karl Dickman/units');//[[User:Karl Dickman/dates.js]] //Function to insert UTC time importScript('Userscripts/Time inserter/source');//[[User:Userscripts/Time inserter/source.js]] importScript('Karl Dickman/permalink&cite'); //} if(skin=="monobook") { gsKateInsertBefore = 'pt-mycontris'; // leave blank to append after "logout" function KateLink() { var user = document.getElementById( 'pt-userpage').firstChild.firstChild.data; var li = document.createElement( 'li' ); li.id = 'pt-kate'; var a = document.createElement( 'a' ); a.appendChild( document.createTextNode( 'Count contributions' ) ); // eh, the css makes the text lowercase a.href = 'http://tools.wikimedia.de/~kate/cgi-bin/count_edits?dbname=enwiki&user=' + user; li.appendChild( a ); if ( ! gsKateInsertBefore ) // append to end (right) of list { document.getElementById( 'pt-logout' ).parentNode.appendChild( li ); } else { var before = document.getElementById( gsKateInsertBefore ); before.appendChild( li, before ); } } if ( window.addEventListener ) window.addEventListener( 'load', KateLink, false ); else if ( window.attachEvent ) window.attachEvent( 'onload', KateLink ); //function to handle dates: importScript('Bobblewik/monobook.js/dates'); //function to handle units: importScript('Bobblewik/monobook.js/unitformatter'); }