Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > Pro JSP
|
Pro JSP Advanced JSP coding questions. Beginning questions will be redirected to the Beginning JSP forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro JSP section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 4th, 2005, 10:09 AM
Registered User
 
Join Date: Mar 2004
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default getParameter with parameter names aut. generated

Hello,
I have a form and the parameter names are generated automatically... that is to say I don't know the parameter names (Those are in fact attributes read from a list).
My question is: When I submit the file, how can I read the parameter names????? I can't do a getParameter(<param_name>) since I don't know the name!!!
Help me please!!

THank you


I generate the form the following way:
<form .... name="attributes" ...>
<table>
<tbody>
<tr>
<%
for (int i=1; i < ainfo1.length; i++)
{
   name=ainfo1[i].getName();
   value = mbsc.getAttribute(mbeanName1,ainfo1[i].getName();
%>
  <td><%=name%>: </td>
  <td>
  <input type=text name=<%=name%> value=<%=value%>>
<%
}
%>
  </td>
  </tr>
<%
}
%>
</tbody>
</table>
<input .....>
</form>





 
Old August 8th, 2005, 03:04 PM
Registered User
 
Join Date: Aug 2005
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You can do a request.getParameterNames(), which will return an enumeration of Strings. With these names, you can retreive the values of the parameters.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Parameter object malfunction - out parameter dash dev C# 2005 6 December 4th, 2007 12:58 PM
windows code generated siji44 Visual Studio 2005 1 September 11th, 2007 12:32 PM
Syntax error using request.getParameter in query tutterrow JSP Basics 1 August 24th, 2006 02:13 PM
dynamically generated submenus elladi Dreamweaver (all versions) 9 December 24th, 2004 08:12 AM
Prob with WEB application when uncheck windows aut msrnivas .NET Web Services 2 July 14th, 2004 10:05 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.