新闻中心 分类>>

java 遍历request中的所有表单数据的实例代码

2026-01-17 02:31:03
浏览次数:
返回列表

实例如下:

Enumeration rnames=request.getParameterNames();

for (Enumeration e = rnames ; e.hasMoreElements() ;) {
     String thisName=e.nextElement().toString();
    String thisValue=request.getParameter(thisName);
    System.out.println(thisName+"-------"+thisValue);
}

以上就是小编为大家带来的java 遍历request中的所有表单数据的实例代码的全部内容了,希望对大家有所帮助,多多支持~

搜索