Drupal: Getting another menu block

(Applies to D6 & D7)

Drupal 6 only gives you one block for each of the menus. Here’s how you get another one for any of the menus.

  1. Login with permission to use (or enable) PHP input filter & create blocks.
  2. Go to Administer > Site building > Blocks.
  3. Click Add.
  4. Enter description and title as necessary.
  5. For the Block body:
    1. Choose PHP Code Input Format.
    2. Enter this code:
      <?php
      echo menu_tree('primary-links');
      /*
      * Other possible values for the parameter:
      * 'navigation'
      * 'secondary-links'
      * 'admin_menu'
      *
      * See API function menu_tree() for details:
      * http://api.drupal.org/api/function/menu_block/6
      */
      ?>
  6. Save the block.
  7. Apply CSS to theme as needed and enjoy.

Add comment: