Changeset 6786 for trunk/wp-admin/includes/image.php
- Timestamp:
- 02/11/2008 09:02:44 AM (19 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/includes/image.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/image.php
r6784 r6786 41 41 } 42 42 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 ); 44 44 45 45 imagedestroy( $image ); // Free up memory … … 154 154 155 155 if ( $max < 0 || $metadata['width'] * $metadata['height'] < $max ) { 156 $max_side = apply_filters( 'wp_thumbnail_max_side_length', 1 28, $attachment_id, $file );156 $max_side = apply_filters( 'wp_thumbnail_max_side_length', 140, $attachment_id, $file ); 157 157 $thumb = wp_create_thumbnail( $file, $max_side ); 158 159 158 if ( @file_exists($thumb) ) 160 159 $metadata['thumb'] = basename($thumb); … … 189 188 return __('The GD image library is not installed.'); 190 189 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 ) ); 192 193 193 194 if ( !is_resource( $image ) )
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)