Make WordPress Core


Ignore:
Timestamp:
03/01/2013 05:14:09 PM (13 years ago)
Author:
ryan
Message:

Use wp_unslash() instead of stripslashes() and stripslashes_deep(). Use wp_slash() instead of add_magic_quotes().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/theme-editor.php

    r23554 r23567  
    6969        $file = $allowed_files['style.css'];
    7070} else {
    71         $relative_file = stripslashes( $file );
     71        $relative_file = wp_unslash( $file );
    7272        $file = $theme->get_stylesheet_directory() . '/' . $relative_file;
    7373}
     
    7979case 'update':
    8080        check_admin_referer( 'edit-theme_' . $file . $stylesheet );
    81         $newcontent = stripslashes( $_POST['newcontent'] );
     81        $newcontent = wp_unslash( $_POST['newcontent'] );
    8282        $location = 'theme-editor.php?file=' . urlencode( $relative_file ) . '&theme=' . urlencode( $stylesheet ) . '&scrollto=' . $scrollto;
    8383        if ( is_writeable( $file ) ) {
Note: See TracChangeset for help on using the changeset viewer.