Revert 23416, 23419, 23445 except for wp_reset_vars() changes. We are going a different direction with the slashing cleanup, so resetting to a clean slate. see #21767

git-svn-id: https://develop.svn.wordpress.org/trunk@23554 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2013-03-01 16:28:40 +00:00
parent 158a124d0b
commit c363aea627
89 changed files with 657 additions and 533 deletions

View File

@@ -220,7 +220,7 @@ add_action( 'update_option_page_on_front', 'update_home_siteurl', 10, 2 );
* @return string
*/
function url_shorten( $url ) {
$short_url = str_replace( 'http://', '', $url );
$short_url = str_replace( 'http://', '', stripslashes( $url ));
$short_url = str_replace( 'www.', '', $short_url );
$short_url = untrailingslashit( $short_url );
if ( strlen( $short_url ) > 35 )
@@ -248,9 +248,9 @@ function wp_reset_vars( $vars ) {
if ( empty( $_GET[$var] ) )
$$var = '';
else
$$var = wp_unslash( $_GET[$var] );
$$var = $_GET[$var];
} else {
$$var = wp_unslash( $_POST[$var] );
$$var = $_POST[$var];
}
}
}
@@ -323,8 +323,8 @@ function set_screen_options() {
if ( !$user = wp_get_current_user() )
return;
$option = wp_unslash( $_POST['wp_screen_options']['option'] );
$value = wp_unslash( $_POST['wp_screen_options']['value'] );
$option = $_POST['wp_screen_options']['option'];
$value = $_POST['wp_screen_options']['value'];
if ( $option != sanitize_key( $option ) )
return;