如何在JSP中动态改变按钮的值
在JSP的List页面,点击按钮时,让按钮的值在两种状态(冻结、解冻)之间切换,下面的代码中只能使第一个按钮能切换,其它的均没有反应,不知道为什么?
<td align="center">
<input name="user_id" type="hidden" value= <%=userId%>>
<input type="button" style="cursor:hand" name="modify" value="修改" onClick="updateUser(' <%=userId%>');" />
<%
if(user_Name.equals("admin"))
{
%>
<input type="button" style="cursor:hand" name="approve" value="审核" disabled="true" />
<input type="button" style="cursor:hand" name="delete1" value="删除" disabled="true"/>
<input type="button" style="cursor:hand" name="freeze1" value="冻结" disabled="true"/>
<%
}
else
{
%>
<input type="button" style="cursor:hand&
相关问答:
<%@page language="java" contentType="text/html;charset=gb2312" import="java.sql.*"%>
<jsp:useBean id="db" class="wang.connectDB"/>
< ......
问题是这样的:
我有一个文件nagiv.jsp 另一个文件failure.jsp包含他,同时nagiv文件中有一个可以跳转到yy.jsp的commandButton,但是我将failure中点击nagiv中的哪个commandButton,也面不会跳转 ......
<html><head><title>[@title]</title>
<meta http-equiv=Content-Type content="text/html; charset=gb2312">
<script language='javascript'>
function diyCheck ......
新手:
tomcat+struts 2.0
jsp 页面直接关联model
现在需要根据model(admin)里面的一个item(id),判断jsp页面出现的内容.
大概流程:
...
<table>
<tr>
<td>
<s:if admin.id is null> ......
在jsp页面中怎么获得Struts2在action中配置的request。
我在后台的配置如下:
List list = new ArrayList();
list.add(users);
ActionContext ct= ActionContext.getContext();
HttpServletRequest requ ......