А тут как ошибка
case 'image/jpeg':
case 'image/jpg':
$type = 'jpg';
break;
case 'image/png':
$type = 'png';
break;
case 'image/gif':
$type = 'gif';
break;
}
$file = 'avatar_upload/'.md5($id).'.'.$type.''; А тут как ошибка
case 'image/jpeg':
case 'image/jpg':
$type = 'jpg';
break;
case 'image/png':
$type = 'png';
break;
case 'image/gif':
$type = 'gif';
break;
}
$file = 'avatar_upload/'.md5($id).'.'.$type.'';