...
var $full_path = "";
...
function do_upload($field = 'userfile') {
...
$this->full_path = $this->upload_path.$this->file_name;
$this->set_image_properties($this->full_path);
...
}
...
function data() {
return array (
...
'full_path' => $this->full_path,
'is_image' => $this->is_image
...
);
}
...
function is_image() {
...
return $this->is_image = (in_array($this->file_type, $img_mimes, TRUE) && exif_imagetype($this->full_path));
}
|
Upload “is_image” data
|
||||||||||||||||
|
||||||||||||||||
|
||||||||||||||||
|
||||||||||||||||
|
||||||||||||||||
