<s:iterator value="#session.list" id="select">
<tr>
<td><s:property value="#select.id"/></td>
<td><s:property value="#select.name"/></td>
<td><s:property value="#select.gender"/></td>
<td><s:property value="#select.major"/></td>
<td><a href="updateinfo.jsp?id=<s:property value="#select.id"/>">修改</a></td>
传一个<s:property>可以,但是
<a href="updateinfo.jsp?id=<s:property value="#select.id"/>&name=<s:property value="#select.name"/>&major=<s:property value="#select.major"/>">就会出现Error parsing HTTP request header
Note: further occurrences of HTTP header parsing errors will be logged at DEBUG level.
java.lang.IllegalArgumentException: Invalid character found in the request target. The valid characters are defined in RFC 7230 and RFC 3986
试了下网上改server.xml和catalina.properties都没用
可以使用多个呀,你们看你的id、name、major在对应的类里面有没有对应的get方法
改server.xml
我看你使用struts2标签,你可以试一下直接使用struts2的a标签,可以使用多个子标签/s:param来进行传值
对于get方法提交数据会有内容大小的限制,你可以看一下你所传的数据是否过于大。建议改用post方法提交数据
建议改用post方法提交数据,一般都用post
你直接传 ?id=select.id&name=select.name&major=select.major这样不可以吗?
你接收参数的时候,不也是一个一个的接收吗?把他们<%=id%>这样放到html里.
在js中使用的时候,在$("#id").val()不就取到值了吗?