JSP question

Hi everybody!!,

I'm making some examples and now I'm working in some ideas to get the practice in order to develope a application.

The thing is: I have a index.jsp with a form like this:

<form name="formulario" action="salto1.do" method="post">

Usuario:

<input type="text" name:"usu"/>

Password:

<input type="password" name:"pass"/>

<input type="submit" value="ACCEDER" name="acceder" />

</form>

So this action will be attend by a servlet called 'Constructor', because in my web.xml I've got something like this:

<servlet-mapping>

<servlet-name>Controlador</servlet-name>

<url-pattern>/controlador</url-pattern>

</servlet-mapping>

<servlet-mapping>

<servlet-name>Controlador</servlet-name>

<url-pattern>*.do</url-pattern>

</servlet-mapping>

And now, in the servlet I want to have access to the user's name and the password that the user introduced in the jsp page but these sentences don't work:

String user = request.getParameter("usu");

String ps = request.getParameter("pass");

My question: how can I do it?

Thanks a lot

[1309 byte] By [Javielloa] at [2007-11-27 5:42:42]
# 1

The description of the problem is very vague.

Many things look incorrect in your code

This:

<input type="text" name:"usu"/>

should really be:

<input type="text" name="usu"/>

similarly the password field.

I would suggest reading about HTML , Front Controller design pattern.

appy77a at 2007-7-12 15:21:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
Thank you so much, appy77.I was reusing code in the jsp file and I did't notice that. What a silly thing!!Thank you and sorry for how is posted the question, In the preview it didn't look like this mess.
Javielloa at 2007-7-12 15:21:36 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...