DEDECMS无法上传图片的解决办法

include/uploadsafe.inc.php里找到以下代码:

$imtypes = array("image/pjpeg", "image/jpeg", "image/gif", "image/png", "image/xpng", "image/wbmp", "image/bmp");
if (in_array(strtolower(trim($ {
    $_key.'_type'
})), $imtypes)) {
    $image_dd = @getimagesize($$_key);
    if (!is_array($image_dd)) {
        exit('Upload filetype not allow !');
    }
}


解决办法:把

$ imtypes = 改成
$ imgtypes =





你可能感兴趣的:(图片,dedecms)