Home > Backend Development > PHP Tutorial > javascript - Has anyone used kindeditor? How do I set up the uploaded image in this rich text? Why do I get an error?

javascript - Has anyone used kindeditor? How do I set up the uploaded image in this rich text? Why do I get an error?

WBOY
Release: 2016-08-04 09:20:56
Original
951 people have browsed it

What needs to be changed and where to change the save path? If anyone knows, please tell me

<code>
An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


Stacktrace:] with root cause
org.apache.jasper.JasperException: Unable to compile class for JSP: 

An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


Stacktrace:
    at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:103)
    at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:366)
    at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:485)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:379)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:354)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:341)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:657)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at cn.qtone.xxt.base.utiltity.UrlFilter.doFilter(UrlFilter.java:114)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:504)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1074)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Thread.java:662)
</code>
Copy after login
Copy after login

Reply content:

What needs to be changed and where to change the save path? If anyone knows, please tell me

<code>
An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


Stacktrace:] with root cause
org.apache.jasper.JasperException: Unable to compile class for JSP: 

An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 117 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
114: %>
115: <%!
116: private String getError(String message) {
117:     JSONObject obj = new JSONObject();
118:     obj.put("error", 1);
119:     obj.put("message", message);
120:     return obj.toJSONString();


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


An error occurred at line: 108 in the jsp file: /editor/jsp/upload_json.jsp
JSONObject cannot be resolved to a type
105:             return;
106:         }
107: 
108:         JSONObject obj = new JSONObject();
109:         obj.put("error", 0);
110:         obj.put("url", saveUrl + newFileName);
111:         out.println(obj.toJSONString());


Stacktrace:
    at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:103)
    at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:366)
    at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:485)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:379)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:354)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:341)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:657)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:357)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at cn.qtone.xxt.base.utiltity.UrlFilter.doFilter(UrlFilter.java:114)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:504)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:170)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1074)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Thread.java:662)
</code>
Copy after login
Copy after login

What error is reported? Take a screenshot or explain. You said you reported an error, who knows?

Do you have write permission?

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template