javaweb
young_qin
这个作者很懒,什么都没留下…
展开
-
如何在Spring框架里配置Druid!!!
1.首先自己搭好Spring框架。2.导入好需要的jar包,建议mav。3.在applicationContext.xml也就是Spring的配置文件中加入context约束。<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframe原创 2020-11-26 17:31:59 · 573 阅读 · 0 评论 -
SSM整合攻略【全】Spring、SpringMVC、Mybatis。
首先:需要配置的是pom.xml<?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.原创 2020-11-23 23:18:44 · 97 阅读 · 1 评论 -
WARNING: An illegal reflective access operation has occurred原因
WARNING: An illegal reflective access operation has occurred。。原因是:JDK版本过高,但不影响当前项目运行。解决方案:将JDK版本降低。原创 2020-11-23 19:41:12 · 3204 阅读 · 0 评论 -
IDEA调试SpringMvc项目时,出错:java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoade
报错信息处理方法:执行后,在WEB-INF在增加了lib目录,里面是项目引用的jar包,点击Apply->OK后重启Tomcat即可解决。原创 2020-11-23 18:11:22 · 123 阅读 · 0 评论 -
SpringMVC实现原生的文件上传
后端:@Controllerpublic class fileController { @RequestMapping("/text") public String test(HttpServletRequest request) throws Exception { System.out.println("test执行了 "); //创建request String realPath = request.getSession().getS原创 2020-11-22 22:39:11 · 103 阅读 · 0 评论 -
SpringMVC入门案列—十步就完成SpringMVC
一:创建Maven项目,添加各种需要的依赖二:配置web.xml中的DispatcherServlet三:配置Tomcat服务器四:编一个hello类/*Controller*/public class hello { public String hello(){ System.out.println("hello!"); return "hello"; }}五:配置SpringConfig.xml,context&mvc的名称空间,原创 2020-11-21 19:05:04 · 98 阅读 · 0 评论 -
Unknown column ‘admin‘ in ‘where clause
String sql=“select * from user where uname=admin”;当我的sql语句是这样的时候会出现Unknown column ‘admin’ in ‘where clause’ 原因是admin 要加上单引号’admin’原创 2020-11-16 20:18:30 · 1548 阅读 · 1 评论 -
Druid数据库连接池配置文件导入抛出空指针异常
解决方案一:检查目录中的properties,笔者Idea2020.3版本,properties放在resourece目录下,且不要写成"/druid.properties"。解决方案二:检查properties的各项配置信息是否正确。这里给大家提供一个笔者的正确运行的properties做参考。username=rootpassword=123url=jdbc:mysql://localhost/girls?&useSSL=false&serverTimezone=UTC&a原创 2020-11-16 18:22:36 · 1248 阅读 · 1 评论 -
SQLyog连接MySQL8.0报2058错误的完美解决方法
引言用SQLyog连接MySQL8.0(社区版:mysql-installer-community-8.0.15.0.msi),出现错误2058(Plugin caching_sha2_password could not be loaded:xxxx),通过查询资料了解了该错误的原因并在本文中提出了该问题的方案。原因该错误提示如下图所示:具体原因:新的MySQL 8.0安装,在初始化数据目录时,将 ‘root’@'localhost’创建帐户,并且该帐户caching_sha2_password原创 2020-11-04 23:59:55 · 1021 阅读 · 0 评论 -
org.xml.sax.SAXParseException; systemId:报错解决方案①
org.xml.sax.SAXParseException; systemId:报错解决方案①本人是在做JAVAWEB时出现的这个问题,也就是当你部署一个新的工程时,启动会报错“org.xml.sax.SAXParseException; systemId:XXXXXX” ,当然我用过好多网上的解决方法,例如检查XML首行,检查端口的问题,删除MANIFEST.MF文件,删除多余的XML语...原创 2018-10-29 23:02:14 · 29074 阅读 · 1 评论