File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Valid JSP Parameters

 
Steve Dyke
Ranch Hand
Posts: 1602
1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am tring to use the value of a checkbox from my JSP in my servlet as a parameter. I am having trouble with it and need help.

The following code is used in my servlet and wheather or not the checkbox is checked or not I get a blank value.

 
Michael Ku
Ranch Hand
Posts: 510
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Would you be more specific? Please provide the JSP code and the Servlet code to retrieve the parameter.

Thank you
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did you really name your request object "arg0"?
 
Paul Clapham
Sheriff
Pie
Posts: 20171
25
MySQL Database
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Ben Souther:
Did you really name your request object "arg0"?
That's how my IDE generates the parameter names when I tell it to create a servlet. But I always rename the parameters to "request" and "response" before I do anything else.
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The following code is used in my servlet and wheather or not the checkbox is checked or not I get a blank value.

Is the value of the checkbox set ? Please post the HTML code of your checkbox.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic