由于我的使用maven,因此工程中没有WEB-INF 下没有lib文包,因此百度富文本插件会引起错误:
org.apache.jasper.JasperException: Unable to compile class for JSP: ........................ An error occurred at line: 12 in the jsp file: /js/ueditor/jsp/controller.jsp ActionEnter cannot be resolved to a type 9: 10: String rootPath = application.getRealPath( "/" ); 11: 12: out.write( new ActionEnter( request, rootPath ).exec() ); 13: 14: %>,解决办法两种:
一是,把ueditor包里面jsp下的lib整个拷下来,放在WEB-INF下面,重启项目问题解决;
二是,导入ueditor的maven依赖包,要与使用的ueditor一致:
<!-- https://mvnrepository.com/artifact/cn.songxinqiang/com.baidu.ueditor --> <dependency> <groupId>cn.songxinqiang</groupId> <artifactId>com.baidu.ueditor</artifactId> <version>1.1.2-offical</version> </dependency>