Make WordPress Core

Opened 15 years ago

Closed 15 years ago

#13138 closed defect (bug) (fixed)

Show warning if the menu name already exists

Reported by: ocean90's profile ocean90 Owned by: filosofo's profile filosofo
Milestone: 3.0 Priority: normal
Severity: normal Version: 3.0
Component: Menus Keywords: needs-patch
Focuses: Cc:

Description

At the moment you get a warning:

Notice: Trying to get property of non-object in H:\xampplite\htdocs\wp\wp-admin\nav-menus.php  on line 208

and a wrong message, because it hasn't been created.

The  menu has been successfully created.

Attachments (4)

do_not_allow_menus_of_same_name.13138.diff (4.9 KB) - added by filosofo 15 years ago.
do_not_allow_menus_of_same_name.2.13138.diff (4.9 KB) - added by filosofo 15 years ago.
make_warning_use_menu_name_slug.13138.diff (8.9 KB) - added by filosofo 15 years ago.
make_warning_use_menu_name_slug.2.13138.diff (8.9 KB) - added by filosofo 15 years ago.

Download all attachments as: .zip

Change History (11)

#1 @ocean90
15 years ago

There is somethink similar:

Create a menu with name 1 and a menu with name 2, after that change the name of 2 to 1. The name of menu 2 should be now 1.

If you change the name, you should also get this warning:

Notice: Undefined index: menu-item-db-id in H:\xampplite\htdocs\wp\wp-admin\nav-menus.php  on line 232

#2 @ocean90
15 years ago

  • Keywords needs-patch added

Not as Cc...

#3 @ocean90
15 years ago

  • Cc ocean90@… added
Notice: Undefined index: menu-item-db-id in H:\xampplite\htdocs\wp\wp-admin\nav-menus.php  on line 232

You get this message, if the menu doesn't have any items.

#4 @filosofo
15 years ago

  • Status changed from new to accepted

#5 @nacin
15 years ago

  • Resolution set to fixed
  • Status changed from accepted to closed

(In [14283]) More nav menu fixes. props filosofo. see #13148. fixes #13155, fixes #13157, fixes #13138, see #13134.

#6 @ocean90
15 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

see #comment:1 and #comment:3

#7 @nacin
15 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [14285]) Fix handling of nav menu search, also menu naming conflicts. props filosofo, fixes #13138

Note: See TracTickets for help on using tickets.