strtolower widget id. Props filosofo. fixes #6949
git-svn-id: http://svn.automattic.com/wordpress/trunk@7915 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
94eb7224bb
commit
6d3c98a56f
|
@ -95,6 +95,8 @@ function register_sidebar_widget($name, $output_callback, $classname = '') {
|
||||||
function wp_register_sidebar_widget($id, $name, $output_callback, $options = array()) {
|
function wp_register_sidebar_widget($id, $name, $output_callback, $options = array()) {
|
||||||
global $wp_registered_widgets;
|
global $wp_registered_widgets;
|
||||||
|
|
||||||
|
$id = strtolower($id);
|
||||||
|
|
||||||
if ( empty($output_callback) ) {
|
if ( empty($output_callback) ) {
|
||||||
unset($wp_registered_widgets[$id]);
|
unset($wp_registered_widgets[$id]);
|
||||||
return;
|
return;
|
||||||
|
@ -164,6 +166,8 @@ function register_widget_control($name, $control_callback, $width = '', $height
|
||||||
*/
|
*/
|
||||||
function wp_register_widget_control($id, $name, $control_callback, $options = array()) {
|
function wp_register_widget_control($id, $name, $control_callback, $options = array()) {
|
||||||
global $wp_registered_widget_controls;
|
global $wp_registered_widget_controls;
|
||||||
|
|
||||||
|
$id = strtolower($id);
|
||||||
|
|
||||||
if ( empty($control_callback) ) {
|
if ( empty($control_callback) ) {
|
||||||
unset($wp_registered_widget_controls[$id]);
|
unset($wp_registered_widget_controls[$id]);
|
||||||
|
|
Loading…
Reference in New Issue