- 博客(10)
- 资源 (2)
- 问答 (1)
- 收藏
- 关注
原创 tomcat自动解压(部署)和热加载使用区别
自动解压:是server.xml文件中Host节点的autoDeploy。意思是把war包放到appBase下面就会被自动解压发布,不用重启tomcat <Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true"> 热加载:是指修改项目内容而自动加载项目,不用重启tomcat <Context path="" docBase="" reloadable="true"/> pat
2020-08-12 12:02:34
892
原创 Spring Boot、Spring security、Spring MVC整合使用,CORS跨域问题
声明:跨域的问题,前端和后端都能解决,CORS本身是在后端解决的,但是前端通过代理使请求变成不跨域也能解决,就看前端和后端开发人员的较量了。 问题:Spring Security提供的login接口访问不成功,OPTIONS预请求报错 报错信息: Access to XMLHttpRequest at 'http://localhost:8080/sockjs-node/info?t=156...
2019-08-06 17:55:31
468
原创 多个audio连续播放
<div id="audio" ng-hide="true"></div> var audio = $('#audio'); //先生成html对象 audio.append('<audio name="audioName" src='+srcStr+($translate.use() == "en" ? "PlsPutItInTheConsolidatio...
2019-04-24 15:36:54
1835
原创 logback异常RuntimeException in Action for tag [encoder] java.lang.NumberFormatException
我的配置文件: <?xml version="1.0" encoding="UTF-8"?> <configuration scan="true" scanPeriod="60"> <appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender&qu
2018-08-19 16:35:08
9845
原创 mybatis绑定错误Invalid bound statement (not found)
本人在eclipse中的项目运行正常,但是部署服务器上报错Invalid bound statement (not found) 有以下几点可能: 1.mapper.xml和mapper接口名称不一样报错 2.mapper.xml和mapper接口不在同一个包下报错 3.如果在tomcat运行的项目路径下没有mapper.xml文件就是打包的时候没有把.xml打包,在pom文件中添加 ...
2018-07-26 21:19:05
929
原创 Struts2的IOC
IOC容器不止spring有,Struts2本身也有一个,而且非常小。 ①用IOC方式访问Servlet IPA。将Servlet对象注入到Action中,需要实现以下接口: ServletContextAware:实现该接口的Action可以直接访问Web应用的ServletContext实例。 ServletRequestAware:实现该接口Action可以直接访问用户请求的HttpS
2017-05-10 15:43:26
421
原创 通用的增删改查方法(反射)附带MySQL数据库连接
/** * 数据库连接类 * getConnection获取一个Connection对象,利用的是从文件中读取配置文件,此处这个配置文件在项目下,不在包下。 * getPreparedStatement(String sql) 赋值前的preparedStatment * setPreparedStatement(PreparedStatement statement, Objec
2016-11-07 20:17:40
1108
原创 MySQL数据库的连接和关闭
public class DButil { public static Connection getConection(){ Connection conn = null; try { Properties ps = new Properties(); FileInputStream fis = new FileInputStream("config.properties");//自定义
2016-10-09 16:10:08
6632
myeclipse中关于整合框架找不到baseDao这个Bean
2017-03-16
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅