diff --git a/regenerate-thumbnails.php b/regenerate-thumbnails.php index 66185ea..29dd2ad 100644 --- a/regenerate-thumbnails.php +++ b/regenerate-thumbnails.php @@ -295,8 +295,12 @@ public function regenerate_interface() { echo '

' . __( 'Regenerate Thumbnails', 'regenerate-thumbnails' ) . "

\n"; + // Make sure image editing is supported + if ( ! wp_image_editor_supports() ) { + echo '

' . __( "Sorry but your server doesn't support image editing which means that WordPress can't create thumbnails. Please ask your host to install the Imagick or GD PHP extensions.", 'regenerate-thumbnails' ) . '

'; + } // Display the introduction page - if ( empty( $_POST['regenerate-thumbnails'] ) && empty( $_REQUEST['ids'] ) ) { + elseif ( empty( $_POST['regenerate-thumbnails'] ) && empty( $_REQUEST['ids'] ) ) { $this->regenerate_interface_introduction(); } // Regenerate button was pushed, so start the operation