📄 vote_do.jsp
字号:
<%@ include file="include.inc"%>
<%@ page contentType="text/html; charset=gb2312" language="java" %>
<% request.setAttribute("remoteHost",request.getRemoteHost());
request.setCharacterEncoding("gb2312");
%>
<c:set var="update_vote" value="update vote set ${param.id}=${param.id}+1 where id=1"/>
<c:set var="update_rec" value="insert into vote_rec values('${remoteHost}',getdate())"/>
<html>
<head>
<title>表达式语言综合举例</title>
</head>
<body bgcolor="#FFFFFF">
<sql:transaction dataSource="${vote}">
<sql:update var="newTable" sql="${update_rec}"/>
</sql:transaction>
<sql:update var="newTable2" sql="${update_vote}" dataSource="${vote}"/>
<c:url value="vote.jsp" var="vote"/>
<c:redirect url="${vote}"/>
</center>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -