Tu banner alternativo

Wikipedia:WikiProject User scripts/Scripts/Re-order menus

In this article, we are going to delve into Wikipedia:WikiProject User scripts/Scripts/Re-order menus, a topic that has aroused great interest in today's society. Wikipedia:WikiProject User scripts/Scripts/Re-order menus is a concept that has gained relevance in various fields, from science to popular culture, and its influence has spread significantly in recent times. Along these lines, we will explore the different facets and dimensions of Wikipedia:WikiProject User scripts/Scripts/Re-order menus, analyzing its impact on everyday life, its relevance in the academic field, as well as its presence in technology and entertainment. Through a multidisciplinary approach, we aim to shed light on Wikipedia:WikiProject User scripts/Scripts/Re-order menus and offer a comprehensive view of this phenomenon that has captured the attention of numerous individuals and groups in contemporary society.

Tu banner alternativo

Add the following to monobook.js:

 function menu_move_to_top(menu_name) {
    menu = document.getElementById(menu_name);
    if (menu) {
       p = menu.parentNode;
       p.removeChild(menu);
       p.insertBefore( menu, p.firstChild );
    }
 }
 addOnloadHook(function (){
    /*
     * Edit the order of this menu_names array to change the order of the toolbox.
     * The names are the ids of the boxes.
     */
    menu_names = [
       "p-search", // search box
       "p-tb", // toolbox
       "p-interaction", // interaction
       "p-navigation", // navigation
       ];
    while ( menu_name = menu_names.pop() ) {
       menu_move_to_top(menu_name);
    }
 });


The menu_names variable sets the order of the menu boxes. For example, moving the search box to the bottom can be done by setting the menu_names variable to:

    menu_names = [
       "p-navigation", // navigation
       "p-interaction", // interaction
       "p-tb", // toolbox
       "p-search", // search box
       ];


--h2g2bob (talk) 13:47, 6 July 2008 (UTC)


Tested with Works?
Internet Explorer 6.0 Unknown
Internet Explorer 7.0 Unknown
Firefox 2.0 Yes
Firefox 3.0 Yes
Safari Unknown
Opera Unknown
Konqueror 3.5 Yes