相关疑难解决方法(0)

Nicedit本地上传图片失败

这就是我打电话给编辑的方式:

new nicEditor({
           buttonList : ['bold','italic','underline','upload'],
           iconsPath:'img/nicedit.png',
           uploadURI : 'http://server.com/integracion/files/nicUpload.php'
}).panelInstance(textareaId);
Run Code Online (Sandbox Code Playgroud)

并且.php文件存在(我是文档中的那个,我更新了目标路径)

/* I want them here http://server.com/integracion/files/uploads/ so... */   
    define('NICUPLOAD_PATH', './uploads'); // Set the path (relative or absolute) to
                                              // the directory to save image files                  
    define('NICUPLOAD_URI', '/uploads');   // Set the URL (relative or absolute) to
                                              // the directory defined above
Run Code Online (Sandbox Code Playgroud)

但是我在上传完成时做出响应(以及从nicedit中提取警告......)

<script>
        try {
            top.nicUploadButton.statusCb({"error":"Invalid Upload ID"});
        } catch(e) { alert(e.message); }
    </script>
Run Code Online (Sandbox Code Playgroud)

我错过了什么?

-编辑

我认为问题可能出在php文件中:

$id = $_POST['APC_UPLOAD_PROGRESS'];  /* APC is installed and enabled */ …
Run Code Online (Sandbox Code Playgroud)

javascript php upload nicedit

3
推荐指数
1
解决办法
9276
查看次数

标签 统计

javascript ×1

nicedit ×1

php ×1

upload ×1