Note : après avoir enregistré vos modifications, il se peut que vous deviez forcer le rechargement complet du cache de votre navigateur pour voir les changements.

  • Firefox / Safari : Maintenez la touche Maj (Shift) en cliquant sur le bouton Actualiser ou pressez Ctrl-F5 ou Ctrl-R (⌘-R sur un Mac) ;
  • Google Chrome : Appuyez sur Ctrl-Maj-R (⌘-Shift-R sur un Mac) ;
  • Internet Explorer : Maintenez la touche Ctrl en cliquant sur le bouton Actualiser ou pressez Ctrl-F5 ;
  • Opera : Allez dans Menu → Settings (Opera → Préférences sur un Mac) et ensuite à Confidentialité & sécurité → Effacer les données d'exploration → Images et fichiers en cache.
/** Change Special:Search to use a drop-down menu *******************************************************
   *
   *  Description: Change Special:Search to use a drop-down menu, with the default being
   *               the internal MediaWiki engine
   *  Created and maintained by: [[User:Gracenotes]]
   */

 if ((wgNamespaceNumber == -1) && (wgCanonicalSpecialPageName == "Search")){
         var searchEngines = [];
 
         addOnloadHook(SpecialSearchEnhancedX);
 }
 
 function SpecialSearchEnhancedX() {
         var createOption = function(site, action, mainQ, addQ, addV) {
                 var opt = document.createElement('option');
                 opt.appendChild(document.createTextNode(site));
                 searchEngines[searchEngines.length] = [action, mainQ, addQ, addV];
                 return opt;
         }
         var searchForm = document.forms['search'];
         if (! searchForm) searchForm = document.forms['powersearch'];
 
         var selectBox = document.createElement('select');
         selectBox.id = 'searchEngine';
 
         searchForm.onsubmit = function() {
                 var optSelected = searchEngines[document.getElementById('searchEngine').selectedIndex];
                 searchForm.action = optSelected[0];
 
                 searchInput = document.getElementById("searchText");
                 if (! searchInput) searchInput = document.getElementById("powerSearchText");
                 searchInput.name = optSelected[1];
 
                 searchForm.title.value = optSelected[3];
                 searchForm.title.name = optSelected[2];
         }
 
         selectBox.appendChild(createOption('Moteur interne', wgScriptPath + '/index.php', 'search', 'title', 'Special:Recherche'));
         selectBox.appendChild(createOption('Google', 'http://www.google.com/search', 'q', 'sitesearch', 'fr.wikisource.org')); 
         selectBox.appendChild(createOption('Windows Live', 'http://search.live.com/results.aspx', 'q', 'q1', 'site:http://fr.wikisource.org'));
         selectBox.appendChild(createOption('Yahoo', 'http://search.yahoo.com/search', 'p', 'vs', 'fr.wikisource.org'));
         selectBox.appendChild(createOption('WiKiwix', 'http://fr.wikiwix.com/index.php', 'action', 'disp', 'source'));
 
         searchInput = document.getElementById("searchText");
         if (! searchInput) searchInput = document.getElementById("powerSearchText");
 
         searchInput.parentNode.insertBefore(selectBox, searchInput.nextSibling);
 }