- 浏览: 81004 次
- 性别:
- 来自: 无锡
最新评论
-
yellowd1:
好少呀。 希望多学点:o
基于MyEclipse 8.0 GA整合S2SH框架实例教程(二) -
yifzeng:
楼主,求图啊。。。。您在这篇教程里配的图怎么都不见了呢。。。
基于MyEclipse 8.0 GA整合S2SH框架实例教程(四) -
qq262549820:
谢谢
MyEclipse 8.0 M1中Vss Plugin的安装
文章列表
1. 提交按钮添加事件
<form method="post" action="userAction">
<input type="submit" value="提交" onclick="return check();"/>
</form>
2. 防止页面重复提交
<script type="text/javascript">
var requestSubmitted = false;
function ...
方法一:
List questionList = (List)this.getHibernateTemplate().find(
"from question where name='" + name + "' and password='" + password +"'"
);
方法二:
List questionList = (List)this.getHibernateTemplate().find(
"from Question q where q.name=? and q.passwo ...
/**
* Copyright (c) 2010 WXIT, Inc. All rights reserved.
* Filename: UserAction.java
* Description: TODO
* Author: qiuxiaorong
* Date: 2010-5-12
* Version: V1.1
*
* Modification History:
* Date Author Version Description
* ----------------------------------- ...
Action中
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
...
HttpServletRequest request = ServletActionContext.getRequest();
HttpSession session = request.getSession();
//统计分数
int iTotalScore;
iTotalScore = Integer.parseInt(session.getAttribute("T ...
1. 去除字符串中前后空格和换行符:
去左空格replace(/(^\s*)/g, ""),去右空格replace(/(\s*$)/g, "")。
string questionName = " a b c ";
questionName = questionName.replace(/\s*$|^\s*/g,"");
最终结果为questionName="a b c"
2. 去除字符串中所有空格和换行符:
string questionName = &quo ...
1. 半角状态下不能输入单引号:[^']+
2. 半角状态下输入12位考籍号:^(\d{12})$
3. 半角状态下输入15位或18位身份证号码:^(\d{15}|\d{17}[\dx|\dX])$
1. 通配符"_"(单个字符)
"_"号表示任意单个字符,该符号只能匹配一个字符。"_"可以放在查询条件的任意位置,且只能代表一个字符,一个汉字只使用一个"_"表示。
2. 通配符"%"(0个或多个字符):
"%"符号是字符匹配符,能匹配0个或更多字符的任意长度的字符串。在SQL语句中可以在查询条件的任意位置放置一个"%"来代表一个任意长度的字符串。在查询条件时也可以放置两个"%"进行查询,但在查询条件中最好不要连续出现两个" ...
CRUD是指在做计算处理时的增加(Create)、查询(Retrieve)(重新得到数据)、更新(Update)和删除(Delete)几个单词的首字母简写。主要被用在描述软件系统中数据库或者持久层的基本操作功能。
In computing, CRUD is an acronym for create, retrieve, update, and delete. It is used to refer to the basic functions of a database or persistence layer in a software system.
C reate new record ...
1. 根据你提交表单的申请JSP服务器容器把HelloWorld.do映射到<servlet-mapping>;
2. JSP服务器容器把<servlet-mapping>的HelloWorld.do指到<action-mappings>的path="/HelloWorld";
3. struts控制器根据name="HelloForm"找<form-beans>中对应的<form-bean>;
4. <form-bean>调用指定的type类。关联: 如果validate是&qu ...
1. 如果struts中配有如下几个action,且UserAction中有与之对应的方法
<action name="listUser" class="com.shawnqiu.action.UserAction" method="list">
<result name="success">/listUser.jsp</result>
</action>
<action name="addUser" class="com ...