Make WordPress Core

Changeset 6786


Ignore:
Timestamp:
02/11/2008 09:02:44 AM (16 years ago)
Author:
matt
Message:

Blow out mem limit, slightly larger thumbnails.

Location:
trunk
Files:
3 edited

Legend:

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

    r6784 r6786  
    4141    }
    4242
    43     @ imagecopyresampled( $thumbnail, $image, 0, 0, 0, 0, $image_new_width, $image_new_height, $sourceImageWidth, $sourceImageHeight );
     43    imagecopyresampled( $thumbnail, $image, 0, 0, 0, 0, $image_new_width, $image_new_height, $sourceImageWidth, $sourceImageHeight );
    4444
    4545    imagedestroy( $image ); // Free up memory
     
    154154
    155155        if ( $max < 0 || $metadata['width'] * $metadata['height'] < $max ) {
    156             $max_side = apply_filters( 'wp_thumbnail_max_side_length', 128, $attachment_id, $file );
     156            $max_side = apply_filters( 'wp_thumbnail_max_side_length', 140, $attachment_id, $file );
    157157            $thumb = wp_create_thumbnail( $file, $max_side );
    158 
    159158            if ( @file_exists($thumb) )
    160159                $metadata['thumb'] = basename($thumb);
     
    189188        return __('The GD image library is not installed.');
    190189
    191     $image = @imagecreatefromstring( @file_get_contents( $file ) );
     190    // Set artificially high because GD uses uncompressed images in memory
     191    @ini_set('memory_limit', '256M');
     192    $image = imagecreatefromstring( file_get_contents( $file ) );
    192193
    193194    if ( !is_resource( $image ) )
  • trunk/wp-includes/functions.php

    r6783 r6786  
    10711071    // separate the filename into a name and extension
    10721072    $info = pathinfo($filename);
    1073     $ext = strtolower( $info['extension'] );
     1073    $ext = $info['extension'];
    10741074    $name = basename($filename, ".{$ext}");
    10751075
     
    10841084            $ext = '';
    10851085        else
    1086             $ext = ".$ext";
     1086            $ext = strtolower( ".$ext" );
    10871087        $filename = $filename . $ext;
    10881088        while ( file_exists( $dir . "/$filename" ) ) {
  • trunk/wp-includes/shortcodes.php

    r6726 r6786  
    147147        <style type='text/css'>
    148148            .gallery {
    149                 width: 450px;
    150                 left: 50%;
    151149                margin: auto;
    152150            }
     
    157155                width: 33%;         }
    158156            .gallery img {
    159                 border: 3px solid #cfcfcf;
     157                border: 2px solid #cfcfcf;
    160158            }
    161159        </style>
Note: See TracChangeset for help on using the changeset viewer.