User:Platonides/vector.js

addPortletLink('p-personal', 'http://www.mediawiki.org/wiki/Special:Code/MediaWiki', 'Code Review', 'p-Code-Review', null, null, document.getElementById('pt-userpage') );

if ( wgPageName == "Special:Code" ) { addOnloadHook( function {  if ( document.getElementById('path') ) {     document.getElementById('path').onchange = function {        var path = document.getElementById('path').value;        var n = path.indexOf( '/' );        switch ( path.substring( 0, n ) ) {          case 'phase3':          case 'extensions':            document.getElementById('path').value = "/trunk/" + path;            break;          case 'skins':          case 'maintenance':          case 'includes':            document.getElementById('path').value = "/trunk/phase3/" + path;            break;        }     }   } }); }