摘要: ubuntu默认自带的是ibus输入平台,提供一个叫pinyin的鸟输入法。本人不是很喜欢用,听说sunpinyin不错,就安装了试试!!!(请参考http://code.google.com/p/sunpinyin/wiki/BuildUnix)step 1:下载安装输入法 下载地址:http://code.google.com/p/sunpinyin/downloads/list 下载最新的两个包:sunpinyin-2.0.3.tar.gz,ibus-sunpinyin-2.0.3.tar.gzstep2:安装依赖组件C++编译器 (sudo aptitude install build 阅读全文
posted @ 2011-09-16 15:36 Spring MVC 3 阅读(957) 评论(0) 推荐(0) 编辑
摘要: jndi(Java Naming and Directory Interface,Java命名和目录接口)是一组在Java应用中访问命名和目录服务的API。命名服务将名称和对象联系起来,使得我们可以用名称访问对象。目录服务是一种命名服务,在这种服务里,对象不但有名称,还有属性。 tomcat配置jndi有全局配置和局部配置。大致的有以下三种配置方式:第一种:全局配置。1)在tomcat的conf文件夹下的context.xml配置文件中加入: <Resource name="jndi/mybatis" auth="Container" type=& 阅读全文
posted @ 2011-08-23 11:44 Spring MVC 3 阅读(11640) 评论(1) 推荐(1) 编辑
摘要: mybatis是ibatis的升级版,spring也有自带mybatis的orm。所以,搭建ibatis的框架也会有多种方式(我这里mybatis是3.0的,ibatis是2.3的,spring是3.0的,数据库是mysql)。下面介绍3中方式1,只是用mybatis3。2,使用mybatis3+spring3(使用mybatis的SqlSessionFactory )。3,使用ibatis2.3+spring(使用spring自带的ibatis)spring的orm包中只有ibatis,没有mybatis。而mybatis和ibatis还是有些区别的,比如配置文件属性不同。第一种方式(只使用 阅读全文
posted @ 2011-08-22 16:47 Spring MVC 3 阅读(4900) 评论(0) 推荐(0) 编辑
摘要: 异常javax.servlet.ServletException: javax.servlet.jsp.JspException: Unable to get connection, DataSource invalid: "org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot load JDBC driver class 'com.mysql.jdbc.Driver'" org.apache.jasper.runtime.PageContextImpl.doHandlePageException(Pa 阅读全文
posted @ 2011-08-22 14:37 Spring MVC 3 阅读(2735) 评论(1) 推荐(1) 编辑
摘要: 异常org.apache.ibatis.exceptions.PersistenceException: ### Error building SqlSession.### The error may exist in com/lgm/mybatis/config/pageAccessURL.xml### Cause: org.apache.ibatis.builder.BuilderException: Error parsing SQL Mapper Configuration. Cause: org.apache.ibatis.builder.BuilderException: Erro 阅读全文
posted @ 2011-08-22 10:01 Spring MVC 3 阅读(1136) 评论(0) 推荐(0) 编辑
摘要: 列子: public static void main(String[] args) throws IOException { File file = new File("F:\\jimmy\\a.txt"); if(!file.exists()) file.createNewFile(); OutputStream out = new FileOutputStream(file); out.write(new String("我\n勒\n了\n个\n去").getBytes()); out.close(); }打开文本,里面内容为:我■勒■了■个■去。 阅读全文
posted @ 2011-08-12 13:21 Spring MVC 3 阅读(501) 评论(0) 推荐(0) 编辑
摘要: 项目:3个filter,3个servlet,匹配的url路径/hello。情况1:servlet没加<load-on-startup></load-on-startup>情况(web.xml配置顺序:first filter,second filter,third filter,first servlet,second servlet,third servlet):初始化tomcat时: this is the first filter init()..... this is the third filter init().... this is the second 阅读全文
posted @ 2011-07-20 17:30 Spring MVC 3 阅读(1458) 评论(0) 推荐(0) 编辑
摘要: 问题:当frame框架下引用了另外一个站点的网页的话,session会存在丢失的情况。解决方案是,加入如下代码:response.addHeader("P3P", "CP=CAO PSA OUR") 阅读全文
posted @ 2011-07-20 15:53 Spring MVC 3 阅读(270) 评论(0) 推荐(0) 编辑
摘要: PS:以后会陆续增加oracle常用sql语句。不定期更新中....-------------------------------------------------------------------------------------------------------------------------------------1. union 和union all使用方法 说明:union all将两个表进行合并,而且要满足两个条件:要有互相匹配的字段类型和字段个数要相同。个人理解“互相匹配的字段类型”是指查询两个表中类型相同且值一致的数据给合并,并且不能是vachar类型的。我试过,只 阅读全文
posted @ 2011-04-14 22:15 Spring MVC 3 阅读(251) 评论(0) 推荐(0) 编辑
摘要: ') .replace(/ /g, '&nbsp '); document.getElementById("toolbar1").style.visibility="hidden"; document.getElementById("toolbar2").style.visibility="hidden"; } else { // convert visual space to actual spaces document.getElementById('edit') 阅读全文
posted @ 2011-04-14 21:38 Spring MVC 3 阅读(386) 评论(0) 推荐(0) 编辑