From 3c5e5e867954db86ea16be6f939f221df1632f5f Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Wed, 17 Mar 2010 06:33:53 +0000 Subject: [PATCH] Unlimited number of pages and custom links for nav-menu. Todo: AJAX-based autocomplete, so this scales better. see #11817 git-svn-id: https://develop.svn.wordpress.org/trunk@13727 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/nav-menu.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-admin/includes/nav-menu.php b/wp-admin/includes/nav-menu.php index 0b4b0b0b3e..43e0ad2cb3 100644 --- a/wp-admin/includes/nav-menu.php +++ b/wp-admin/includes/nav-menu.php @@ -98,7 +98,7 @@ function wp_nav_menu_create_metabox() { ?> * @since 3.0.0 */ function wp_nav_menu_item_link_metabox() { - $args = array( 'post_status' => 'any', 'post_type' => 'nav_menu_item', 'meta_value' => 'custom' ); + $args = array( 'post_status' => 'any', 'post_type' => 'nav_menu_item', 'meta_value' => 'custom', 'showposts' => -1 ); // @todo transient caching of these results with proper invalidation on updating links $query = new WP_Query( $args ); @@ -145,7 +145,7 @@ function wp_nav_menu_item_link_metabox() { * @param string $post_type The post type object. */ function wp_nav_menu_item_post_type_metabox( $object, $post_type ) { - $args = array( 'post_type' => $post_type['args']->name, 'post_status' => 'publish' ); + $args = array( 'post_type' => $post_type['args']->name, 'post_status' => 'publish', 'showposts' => -1 ); if ( 'attachment' == $post_type['args']->name ) $args['post_status'] = 'any';