Don't echo empty <h3>s if we don't pass a section title to add_settings_section(). see #18045.

git-svn-id: http://svn.automattic.com/wordpress/trunk@18432 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
nacin 2011-07-11 20:22:24 +00:00
parent 01060c0689
commit 916a1c943c
1 changed files with 2 additions and 1 deletions

View File

@ -1163,7 +1163,8 @@ function do_settings_sections($page) {
return;
foreach ( (array) $wp_settings_sections[$page] as $section ) {
echo "<h3>{$section['title']}</h3>\n";
if ( $section['title'] )
echo "<h3>{$section['title']}</h3>\n";
call_user_func($section['callback'], $section);
if ( !isset($wp_settings_fields) || !isset($wp_settings_fields[$page]) || !isset($wp_settings_fields[$page][$section['id']]) )
continue;