Don't default to an unselectable image size. Props tellyworth. fixes #7528 for trunk
git-svn-id: http://svn.automattic.com/wordpress/trunk@8670 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
42b36e1e64
commit
4104795d70
|
@ -549,6 +549,9 @@ function image_size_input_fields($post, $checked='') {
|
|||
// is this size selectable?
|
||||
$enabled = ( $downsize[3] || 'full' == $size );
|
||||
$css_id = "image-size-{$size}-{$post->ID}";
|
||||
// if this size is the default but that's not available, don't select it
|
||||
if ( $checked && !$enabled )
|
||||
$checked = '';
|
||||
// if $checked was not specified, default to the first available size that's bigger than a thumbnail
|
||||
if ( !$checked && $enabled && 'thumbnail' != $size )
|
||||
$checked = $size;
|
||||
|
|
Loading…
Reference in New Issue