Typo fix from Viper007Bond. fixes #6358

git-svn-id: http://svn.automattic.com/wordpress/trunk@7487 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2008-03-23 16:34:28 +00:00
parent d2143e92ed
commit b274b643a1
1 changed files with 3 additions and 3 deletions

View File

@ -144,7 +144,7 @@ function wp_dashboard_setup() {
if ( 'POST' == $_SERVER['REQUEST_METHOD'] && isset($_POST['widget_id']) ) { if ( 'POST' == $_SERVER['REQUEST_METHOD'] && isset($_POST['widget_id']) ) {
ob_start(); // hack - but the same hack wp-admin/widgets.php uses ob_start(); // hack - but the same hack wp-admin/widgets.php uses
wp_dashbaord_trigger_widget_control( $_POST['widget_id'] ); wp_dashboard_trigger_widget_control( $_POST['widget_id'] );
ob_end_clean(); ob_end_clean();
wp_redirect( remove_query_arg( 'edit' ) ); wp_redirect( remove_query_arg( 'edit' ) );
exit; exit;
@ -212,7 +212,7 @@ function wp_dashboard_dynamic_sidebar_params( $params ) {
$content_class .= ' dashboard-widget-control'; $content_class .= ' dashboard-widget-control';
$wp_registered_widgets[$widget_id]['callback'] = 'wp_dashboard_empty'; $wp_registered_widgets[$widget_id]['callback'] = 'wp_dashboard_empty';
$sidebar_widget_name = $wp_registered_widget_controls[$widget_id]['name']; $sidebar_widget_name = $wp_registered_widget_controls[$widget_id]['name'];
$params[1] = 'wp_dashbaord_trigger_widget_control'; $params[1] = 'wp_dashboard_trigger_widget_control';
$sidebar_before_widget .= '<form action="' . remove_query_arg( 'edit' ) . '" method="post">'; $sidebar_before_widget .= '<form action="' . remove_query_arg( 'edit' ) . '" method="post">';
$sidebar_after_widget = "<div class='dashboard-widget-submit'><input type='hidden' name='sidebar' value='wp_dashboard' /><input type='hidden' name='widget_id' value='$widget_id' /><input type='submit' value='" . __( 'Save' ) . "' /></div></form>$sidebar_after_widget"; $sidebar_after_widget = "<div class='dashboard-widget-submit'><input type='hidden' name='sidebar' value='wp_dashboard' /><input type='hidden' name='widget_id' value='$widget_id' /><input type='submit' value='" . __( 'Save' ) . "' /></div></form>$sidebar_after_widget";
$links[] = '<a href="' . remove_query_arg( 'edit' ) . '">' . __( 'Cancel' ) . '</a>'; $links[] = '<a href="' . remove_query_arg( 'edit' ) . '">' . __( 'Cancel' ) . '</a>';
@ -501,7 +501,7 @@ function wp_dashboard_empty( $sidebar_args, $callback = false ) {
/* Dashboard Widgets Controls. Ssee also wp_dashboard_empty() */ /* Dashboard Widgets Controls. Ssee also wp_dashboard_empty() */
// Calls widget_control callback // Calls widget_control callback
function wp_dashbaord_trigger_widget_control( $widget_control_id = false ) { function wp_dashboard_trigger_widget_control( $widget_control_id = false ) {
global $wp_registered_widget_controls; global $wp_registered_widget_controls;
if ( is_scalar($widget_control_id) && $widget_control_id && isset($wp_registered_widget_controls[$widget_control_id]) && is_callable($wp_registered_widget_controls[$widget_control_id]['callback']) ) if ( is_scalar($widget_control_id) && $widget_control_id && isset($wp_registered_widget_controls[$widget_control_id]) && is_callable($wp_registered_widget_controls[$widget_control_id]['callback']) )
call_user_func_array( $wp_registered_widget_controls[$widget_control_id]['callback'], $wp_registered_widget_controls[$widget_control_id]['params'] ); call_user_func_array( $wp_registered_widget_controls[$widget_control_id]['callback'], $wp_registered_widget_controls[$widget_control_id]['params'] );