UEditor1.4.3上傳圖片提示上傳失敗

經過UEditor1.4.3上傳圖片附件時,提示上傳錯誤。發現JS報錯以下圖:html

UEditor的asp目錄下controller.asp?action=uploadimage文件報500錯誤。app

打開頁面,具體錯誤內容爲:spa

ADODB.Stream 錯誤 '800a0bb9'code

參數類型不正確,或不在能夠接受的範圍以內,或與其餘參數衝突。orm

/ueditor/asp/MultiformProcessor.class.asp,行 73htm

解決辦法:blog

打開文件ueditor\asp\Uploader.Class.asp,找到大概203行處。圖片

改前:ip

 

Private Function CheckOrCreatePath( ByVal path )
        Set fs = Server.CreateObject("Scripting.FileSystemObject")
        Dim parts
        parts = Split( path, "\" )
        path = ""
        For Each part in parts
            path = path + part + "\"
            If fs.FolderExists( path ) = False Then
                fs.CreateFolder( path )
            End If
        Next
    End Function

 

改後:it

Private Function CheckOrCreatePath( ByVal path )
    Set fs = Server.CreateObject("Scripting.FileSystemObject")
    Dim parts
        Dim root : root = Server.mappath("/") & "\"
    'parts = Split( path, "\" )
        parts = Split( Replace(path, root, ""), "\" )
    'path = ""
        path = root
    For Each part in parts
      path = path + part + "\"
      If fs.FolderExists( path ) = False Then
        fs.CreateFolder( path )
      End If
    Next
  End Function

其它解決方法:

文件夾asp中有個文件uploader.class.asp,其中有個檢查或建立路徑的子程序Private Function CheckOrCreatePath( ByVal path ),在這段程序中有兩句 parts = Split( path, "\" )和path = path + part + "\",你把這兩句中的反斜槓都改爲「/」,也就是這兩句最後應當分別是parts = Split( path, "/" )和path = path + part + "/",這樣就能夠了。

UEditor其它相關問題:

http://www.cnblogs.com/cdxkyz/p/4007782.html

相關文章
相關標籤/搜索