|
@@ 462-466 (lines=5) @@
|
| 459 |
|
} |
| 460 |
|
list($img_width, $img_height) = @getimagesize($uploaded_file); |
| 461 |
|
if (is_int($img_width)) { |
| 462 |
|
if ($this->options['max_width'] && $img_width > $this->options['max_width']) { |
| 463 |
|
$file->error = $this->get_error_message('max_width'); |
| 464 |
|
return false; |
| 465 |
|
} |
| 466 |
|
if ($this->options['max_height'] && $img_height > $this->options['max_height']) { |
| 467 |
|
$file->error = $this->get_error_message('max_height'); |
| 468 |
|
return false; |
| 469 |
|
} |
|
@@ 470-474 (lines=5) @@
|
| 467 |
|
$file->error = $this->get_error_message('max_height'); |
| 468 |
|
return false; |
| 469 |
|
} |
| 470 |
|
if ($this->options['min_width'] && $img_width < $this->options['min_width']) { |
| 471 |
|
$file->error = $this->get_error_message('min_width'); |
| 472 |
|
return false; |
| 473 |
|
} |
| 474 |
|
if ($this->options['min_height'] && $img_height < $this->options['min_height']) { |
| 475 |
|
$file->error = $this->get_error_message('min_height'); |
| 476 |
|
return false; |
| 477 |
|
} |