dedecms织梦让上传的图片名字不变保持原名
打开 \include\dialog\select_images_post.php 找到
<span style="font-family:tahoma,geneva,sans-serif;"><span style="font-size:14px;">$filename_name = $cuserLogin->getUserID().'-'.dd2char(MyDate("ymdHis", $nowtme).mt_rand(100,999));</span></span>
改成
打开 \include\helpers\upload.helper.php 找到
<span style="font-family:tahoma,geneva,sans-serif;"><span style="font-size:14px;">$fs2 = explode('.', $imgfile_name);
$filename_name = $fs2[count($fs2)-2];//缩略图不重命名</span></span>
改成
<span style="font-family:tahoma,geneva,sans-serif;"><span style="font-size:14px;">$filename = $cuserLogin->getUserID().'-'.dd2char(MyDate('ymdHis', time())).$rnddd;</span></span>
继续找到
<span style="font-family:tahoma,geneva,sans-serif;"><span style="font-size:14px;">if($ftype=='imagelit') $filename .= '-L';</span></span>
删除或者注释掉这行
打开 \dede\swfupload.php 找到
<span style="font-family:tahoma,geneva,sans-serif;"><span style="font-size:14px;">$filename = $cuserLogin->getUserID().'-'.dd2char(MyDate('ymdHis', time())).$rnddd;</span></span>
改成
<span style="font-family:tahoma,geneva,sans-serif;"><span style="font-size:14px;">$file_snames = explode('.', $Filename);
$filename = $file_snames[count($file_snames)-2];//缩略图不重命名</span></span>