<logic:iterate id="book" name="result" type="com.bright.bean.Book"> <logic:present name="book">
<html:link target="" href="update.do?id=<%=book.getId() %>">
或
<html:link target="" action="update.do?id=<%=book.getId() %>">
book.getId()是整型的.
为什么我到了UpdateAction不能去到值呢还有在<logic:iterate id="book" name="result" type="com.bright.bean.Book">里面可以有<html:form><html:submit></html:submit></html:form>提交和相应的actionForm吗
<html:link target="" href="update.do?id=<%=book.getId() %>">
或
<html:link target="" action="update.do?id=<%=book.getId() %>">
book.getId()是整型的.
为什么我到了UpdateAction不能去到值呢还有在<logic:iterate id="book" name="result" type="com.bright.bean.Book">里面可以有<html:form><html:submit></html:submit></html:form>提交和相应的actionForm吗
<logic:present name="result">
<logic:notEmpty name="result">
<logic:iterator .....>
......
</logic:iterator>
</logic:notEmpty>
</logic:present>你后面的问题,你想把form放到循环里面肯定是不行的,而且也没有必要,放到上面代码的
<logic:present name="result"> 这一句前面就行了。
<html:link page="/update.do" paramId="id" paramName="book" paramProperty="id">
<bean:write name="book" property="id" /></html:link>
你门说呢帮帮我啊
同意上述公约者·申请加入!
QQ群号:25922618(一群)-----人员快满
QQ群号:17615698(二群)-----最近新群
不知道我是否说明白了,上面的方法我用的没问题。我也是新手。如果你还不明白可以查一下 html:link包含请求变量的相关信息。
<tr><th>id</th><th>client_type</th><th>money</th><th>data</th><th>id_client</th><th></th><th></th></tr> <logic:present name="result"> <logic:iterate id="Payments" name="result" type="com.bright.bean.Payments"> <logic:present name="Payments">
<tr>
<td><html:text name="Payments" property="id" size="10"/></td>
<td><html:text name="Payments" property="client_type" size="10"/></td>
<td><html:text name="Payments" property="money" size="10"/></td>
<td><html:text name="Payments" property="data" size="10"/></td>
<td><html:text name="Payments" property="id_client" size="10"/></td>
<td><html:link action="upayments.do?id=<%=Payments.getId() %>">eid</html:link></td>
</tr> </logic:present> </logic:iterate> </logic:present> </table> </body>那我这里的代码为什么就不可以了呢
<input type="button" name="update" onclick="doUpdate('<bean:write
name="book" property="id" />','<bean:write
name="book" property="userName" />','<bean:write
name="book" property="password" />','<bean:write
name="book" property="department" />')"
value="update">
在写个方法:
function doUpdate(arg1,arg2,arg3,arg4){
document.updateform.id.value=arg1;
document.updateform.userName.value=arg2;
document.updateform.password.value=arg3;
document.updateform.department.value=arg4;
document.updateform.submit();
}
这样也可以解决传多个值得问题。
<bean:write name="book" property="id" /> </html:link>
我要传个Map型的东西进去要怎么传呢
Map里面的值是里面的值是是整形封装成Integer个类型
怎么就写呢我写了就是报错误
好难啊小弟写不出来请大家指教了
有相关的例子吗请发大.cn
也可以把相关的代码放到上面让我参考.
谢谢了