Ueditor is the Baidu editor, in the local IIS environment can upload pictures, but placed in the server's IIS environment could not upload pictures, after the search found that IIS setup issues, the main reason for this problem is that most virtual hosts do not give IIS Anonymous account access to the disk's non-user directory, There is no permission to read, since we cannot resolve the IIS issue only from the code set, as follows.
Upload the picture, you can use the browser's own debugging tools to view the error, you can see an "Access denied or the file already exists" errors. Careful debugging analysis, finally found the problem.
In its upload.class.asp, like the next function:
Private Function Checkorcreatepath (ByVal path)
Set fs = Server.CreateObject ("Scripting.FileSystemObject")
Dim parts
parts = Split (path, "\")
Path = "For each part,
parts
Path = path + part +" \ "
If fs.f Olderexists (path) = False Then
fs. CreateFolder (path) end
If
Next
Function
Modify it as follows:
Private Function Checkorcreatepath (ByVal path)
Set fs = Server.CreateObject ("Scripting.FileSystemObject")
Dim Parts
Dim Root:root = Server.MapPath ("/") & "\"
' parts = Split (path, "\")
parts = Split (Replace p Ath, Root, ""), "\" "
Path =" "Path = root for each part in
parts
Path = path + part +" \ "
If fs. FolderExists (path) = False Then
fs. CreateFolder (path) end
If
Next
Function
The problem of uploading can be solved.