Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Loosing String Values in an Array in a JSP

Status
Not open for further replies.

aahan

Programmer
Mar 28, 2002
15
US
Hi,

I have a JSP , a subset of which, having problem is as under :

<html>
<body>
<input type=&quot;text&quot; name=&quot;myname&quot; value=&quot;ABC&quot;><br>
<input type=&quot;text&quot; name=&quot;myname&quot; value=&quot;JKL&quot;><br>
<input type=&quot;text&quot; name=&quot;myname&quot; value=&quot;XYZ&quot;>
<table>
<%
{ int i;
String newnames[] = request.getParameterValues(&quot;myname&quot;);
for ( i = 1 ; i <= 3; i++ ) {
out.print(&quot;<tr><td>&quot; + newnames + &quot;</td></tr>&quot;); }
}
%>
</table>
</body>
</html>

I am interested in storing the values in the array newnames.

Is this possible and what code change do I require to attain this.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top