From 6c039094883efaf852770924ab9d3a9ef087ecc8 Mon Sep 17 00:00:00 2001 From: nacin Date: Sat, 30 Oct 2010 06:14:15 +0000 Subject: [PATCH] Fix nested HTML in submit_button(). fixes #15257, see #15064. git-svn-id: http://svn.automattic.com/wordpress/trunk@16097 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/template.php | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php index cf4bb98b2e..37d0e3fbd3 100644 --- a/wp-admin/includes/template.php +++ b/wp-admin/includes/template.php @@ -2149,12 +2149,11 @@ function get_submit_button( $text = NULL, $type = 'primary', $name = 'submit', $ } // Default the id attribute to $name unless an id was specifically provided in $other_attributes - $id = 'id="' . esc_attr( $name ) . '" '; - if ( is_array( $other_attributes ) && array_key_exists( 'id', $other_attributes ) ) { - $id = 'id="' . esc_attr( $other_attributes['id'] ) . '" '; - } + $id = $name; + if ( is_array( $other_attributes ) && isset( $other_attributes['id'] ) ) + $id = $other_attributes['id']; - $button = ''; if ( $wrap ) {