From 9768611dc13e1f1c869c62d1920f443e569b2e2f Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Sat, 10 Mar 2007 05:26:28 +0000 Subject: [PATCH] Make sure imageantialias exists. Props rob1n and jeppe. fixes #3939 git-svn-id: https://develop.svn.wordpress.org/trunk@5016 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/admin-functions.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/wp-admin/admin-functions.php b/wp-admin/admin-functions.php index d8b92952d6..9468d7c299 100644 --- a/wp-admin/admin-functions.php +++ b/wp-admin/admin-functions.php @@ -2087,7 +2087,9 @@ function wp_crop_image( $src_file, $src_x, $src_y, $src_w, $src_h, $dst_w, $dst_ $src_h -= $src_y; } - imageantialias( $dst, true ); + if (function_exists('imageantialias')) + imageantialias( $dst, true ); + imagecopyresampled( $dst, $src, 0, 0, $src_x, $src_y, $dst_w, $dst_h, $src_w, $src_h ); if ( !$dst_file )