FCKeditor支持上传中文文件
事实上来说,并不是支持上传中文文件,而是支持自动重命名文件。我们可以让用户上传后的图片自动重命名成时间日期格式这样的,能够不重复的进行移动。
需要是修改文件:fckeditor\editor\filemanager\upload\php\upload.php
- while ( true )
- {
- // Compose the file path.
- $sFilePath = $sServerDir . $sFileName ;
- ……
- }
在“// Compose the file path”这行下面增加一个命名文件的过程,修改后如下:
- while ( true )
- {
- // Compose the file path.
- $sFileName = time() . '_' . rand(10000, 99999) . '.' . $sExtension; // 自动重命名文件
- $sFilePath = $sServerDir . $sFileName ;
- ……
- }
感谢您的关注。您现在可以 留言(0) 或 留下通告地址 。
相关信息
该文章 2007年03月27日 提交,位于分类 JavaScript 下. 标签: .上一篇: 如何通过rsync同步FreeBSD和Windows »
下一篇: FCKeditor载入顺序 »

