- 博客(130)
- 收藏
- 关注
原创 ModelDriven<T>
public class LoginAction extends ActionSupport implements ModelDriven{private T t = new T();//这里需要new,否则取不到东西public T getModel(){return t;}}
2012-03-18 10:46:17 510
原创 JSP
select 要让某个值被选中,应在option里面设置selected属性。selected >${type}setTimeout(str, timeout); 第一个参数为string,要执行的语句,可以有多句setTimeout('enable()', 5000);button.disabled = true;让button不可用docu
2012-03-15 23:19:05 229
原创 Oracle Blob
insert的时候插入empty_bolb(),然后用行级锁锁定行,得到blob对象(oracle.sql.Blob),获取其binaryStream,然后用blob.length()得到该对象大小(为什么不能用binaryStream的available()方法,It is never correct to use the return value of this method to alloc
2012-03-15 14:36:37 456
原创 正则表达式使用
Pattern p = Pattern.compile("(?<=st)"); Matcher m = p.matcher("testtest123"); StringBuffer sb = new StringBuffer(); while(m.find()) m.appendReplacement(sb, "\r\n"); m.appendTail(sb); Syst
2012-03-15 14:06:11 644 2
原创 关于String 的正则
String 的 replace是不使用正则功能的。replaceAll和replaceFirst会使用正则。split(regex, n) n n=0时,匹配任意多次,但将结尾空字符串去掉 n>0时,最多匹配n-1次,也就是说数组的长度最大为n.
2012-03-14 23:00:47 375
原创 Proxool pool的配置
配置web.xml ServletConfiguratororg.logicalcobwebs.proxool.configuration.ServletConfiguratorxmlFileWEB-INF/proxool.xml1lib下新建proxool.xml store-ds
2012-03-11 16:27:27 402
原创 Oracle ORA-00979
Oracle:查询结果中使用的字段和order by中使用的字段都要放到group by中,聚合函数除外alter table books modify title varchar2(80);修改表结构
2012-03-11 13:13:39 460
原创 struts-No configuration found for the specified action
struts.xml配置了namespace="/admin"(注意'/')1.如果jsp中用struts的标签,则加上namespace="/admin" action="xxx"(form )2.如果jsp中使用HTML标签,则action="/admin/xxx.action"
2012-02-29 19:07:26 394
原创 jQuery之可编辑表格的实现
$(document).ready(function(){$('table tr:even').css('background-color', '#ECE9D8');$('table tr:first').css('background-color', '#A3BAE9');$('table td').click(function(){var tdNode = $(this
2012-01-24 16:18:48 292
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人