i insert image in page and strangely I get a picture of the types.
show type with: $_FILES['img']['type'].
Result:
Firefox: image/jpeg
IE7: 'image/pjpeg'
Firefox: image/png
IE7: image/x-png
Now i use this filter:
$type_filter = array('image/gif', 'image/jpeg', 'image/png', 'image/jpg', 'image/bmp', 'image/x-png', 'image/pjpeg');
It is goo开发者_开发问答d, or something else is missing? Thanks
I usually do something like this:
if(stristr($_FILES['image']['type'], "image")){
enter code here
}
精彩评论