Make WordPress Core

Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#23271 closed defect (bug) (invalid)

show_option_none_value is not used when using wp_dropdown_pages

Reported by: titan21 Owned by:
Priority: normal Milestone:
Component: WordPress.org Site Version:
Severity: normal Keywords:
Cc: Focuses:

Description

According to the document ion at ​http://codex.wordpress.org/Function_Reference/wp_dropdown_pages. We should be able to specify use the following:

		wp_dropdown_pages(array(
				"post_type"=>"page",
				"show_option_none" => "--Not Selected--",
				"show_option_none_value" => "notselected"				));

When the html is output, we should expect that the <option> with the text "--Not Selected--" should have a value attribute of "notselected". The value attribute is output but not the value:

<option value="">--Not Selected--</option>

I have tried this with pages and a custom post type which results in the same issue.

Could someone confirm this is a valid bug?

Change History (2)

#1 @kovshenin
14 years ago

  • Cc kovshenin added
  • Keywords 2nd-opinion removed
  • Milestone Awaiting Review
  • Resolution → invalid
  • Status new → closed

This is not a bug. The argument name is option_none_value, not show_option_none_value. I updated the codex to reflect that.

#2 @ocean90
14 years ago

  • Component General → WordPress.org site
  • Version 3.5

See [10069].

Note: See TracTickets for help on using tickets.