Make WordPress Core


Ignore:
Timestamp:
08/06/2011 09:04:15 PM (13 years ago)
Author:
azaozz
Message:

Fix handling of resizing images after upload, props ocean90, see #18206

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/file.php

    r18482 r18517  
    331331
    332332    // If a resize was requested, perform the resize.
    333     $do_resize = apply_filters( 'wp_upload_resize', isset( $_REQUEST['image_resize'] ) );
     333    $image_resize = isset( $_POST['image_resize'] ) && 'true' == $_POST['image_resize'];
     334    $do_resize = apply_filters( 'wp_upload_resize', $image_resize );
    334335    $size = @getimagesize( $tmp_file );
    335336    if ( $do_resize && $size ) {
Note: See TracChangeset for help on using the changeset viewer.