Go4Expert

Go4Expert (http://www.go4expert.com/)
-   JSP (http://www.go4expert.com/forums/jsp/)
-   -   splitting parameter names as in PHP (http://www.go4expert.com/forums/splitting-parameter-names-php-t22846/)

ororo 28Jul2010 17:02

splitting parameter names as in PHP
 
Dear all,
I am new to JSP and I was used programming in PHP.
In PHP, there is a useful feature: names of parameters are correctly splitted, so that

<input name="myvar[1]" ...>
<input name="myvar[2]" ...>

generates correctly the array
$_REQUEST['myvar']
with entries [1] and [2]

while in JSP I can only see two different parameters:

request.getParameter('myvar[1]')
request.getParameter('myvar[2]')

So, my answer is, is there any way to access the array
request.getParameter('myvar')
????

Thank you.

ororo 28Jul2010 17:30

Re: splitting parameter names as in PHP
 
EDIT: Sorry, "my question", and not "my answer" ;)


All times are GMT +5.5. The time now is 03:36.