WordPress.org

Make WordPress Core

Changeset 14592


Ignore:
Timestamp:
05/13/10 03:50:26 (5 years ago)
Author:
nacin
Message:

Allow wp_nav_menu_items filters to run on the backend as well. props NathanRice, fixes #13371.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/nav-menu-template.php

    r14591 r14592  
    252252 
    253253    // Allow plugins to hook into the menu to add their own <li>'s 
    254     if ( 'frontend' == $args->context ) { 
    255         $items = apply_filters( 'wp_nav_menu_items', $items, $args ); 
    256         $items = apply_filters( "wp_nav_menu_{$menu->slug}_items", $items, $args ); 
    257         $nav_menu .= $items; 
    258     } else { 
    259         $nav_menu .= $items; 
    260     } 
     254    $items = apply_filters( 'wp_nav_menu_items', $items, $args ); 
     255    $items = apply_filters( "wp_nav_menu_{$menu->slug}_items", $items, $args ); 
     256    $nav_menu .= $items; 
    261257    unset($items); 
    262258 
Note: See TracChangeset for help on using the changeset viewer.