摘要: jquery 使用方法 jQuery是目前使用最广泛的javascript函数库。据统计,全世界排名前100万的网站,有46%使用jQuery,远远超过其他库。微软公司 甚至把jQuery作为他们的官方库。对于网页开发者来说,学会jQuery是必要的。因为它让你了解业界最通用的技术,为将来学习更高级... 阅读全文
posted @ 2015-11-16 15:16 夏末、初秋 阅读(169) 评论(0) 推荐(0) 编辑
摘要: resultType:直接表示返回类型resultMap:对外部resultMap的引用二者不能同时使用创建一个实体类Role和Userpublic class Role { private Integer id; private String roleCode; private ... 阅读全文
posted @ 2015-11-12 16:51 夏末、初秋 阅读(963) 评论(0) 推荐(0) 编辑
摘要: 这2种方法的区别:1、添加接口 2、运用接口来实现其他的都一样添加接口//接口的名字和xml的名字一样,这样xml中的namespace就不用改public interface UserMapper { //接口名的方法名一定要和xml中的id名一样 public int count()... 阅读全文
posted @ 2015-11-12 12:02 夏末、初秋 阅读(447) 评论(0) 推荐(0) 编辑
摘要: 在UserMapper.xml中添加增删改查 insert into user(userCode,userName,userPassword) values (#{userCode},#{userName},#{userPa... 阅读全文
posted @ 2015-11-12 11:31 夏末、初秋 阅读(324) 评论(0) 推荐(0) 编辑
摘要: 增加@Test public void addTest(){ String resource = "mybatis-config.xml"; SqlSession sqlSession = null; try { User use... 阅读全文
posted @ 2015-11-12 10:57 夏末、初秋 阅读(873) 评论(0) 推荐(0) 编辑
摘要: 搭建MyBatis开发环境,实现用户表记录数查询 1、在MyEclipse中创建工程,导入MyBatis的jar包 2、创建MyBatis配置文件mybatis-config.xml配置数据库信息mybatis-config.xml文件 ... 阅读全文
posted @ 2015-11-12 09:24 夏末、初秋 阅读(7142) 评论(0) 推荐(0) 编辑
摘要: 首先添加json包访问:http://localhost:8080/springmvc3/user/view/3返回的是:=============查看用户信息=========== ID:3userName:T03password:333333email:tO3@bdqn.cn访问:http://... 阅读全文
posted @ 2015-11-11 15:13 夏末、初秋 阅读(219) 评论(0) 推荐(0) 编辑
摘要: http://localhost:8080/Springmvc/user/page.do?pageSize=3&pageNow=2你可以把这地址分开理解,其中问号前半部分:http://localhost:8080/Springmvc/user/page.do 这个就是路径,是你的请求url,而如果... 阅读全文
posted @ 2015-11-11 14:53 夏末、初秋 阅读(256) 评论(0) 推荐(0) 编辑
摘要: 首先要导入2个包(上传文件包和io的包)配置文件spring-servlet.xml文件中 如果id="multipartResolver"没传,就会报以下的错(小心小心)Request processing failed; nested exception is ja... 阅读全文
posted @ 2015-11-11 14:40 夏末、初秋 阅读(363) 评论(0) 推荐(0) 编辑
摘要: 在页面的下/statics/css/main.css" type="text/css"/>在webroot目录下添加一个静态文件statics包,然后里面建立各种静态的包(例如css)新建一个xx.css文件,如下*{ font-size:16px; color:red}在spirng-... 阅读全文
posted @ 2015-11-11 11:44 夏末、初秋 阅读(306) 评论(0) 推荐(0) 编辑