*/ private function getImageName($options) { $name = $this->file['name']; if (isset($options['name'])) { $name = $options['name'] . '.' . $this->config['ext']; } return $name; } /** * Resgata nomes dos uploads */ public function getName() { return $this->name; } /** * Verifica se é imagem o upload */ public function isImage() { $images = array('jpg', 'jpeg', 'gif', 'png'); if (in_array($this->info['ext'], $images)) { return true; } return false; } } $image = new ImageResize(); $image->display();