Contact Us
  
 
 
    SearchSearch   RegisterRegister   Log inLog in 

retrieving value from a request object in radio button JSP

retrieving value from a request object in radio button JSP

 
Post new topic   Reply to topic     Forum Index -> Java,Struts framework, Velocity, JSF, Hibernate, Servlet, JSP, javaBeans
View previous topic :: View next topic  
Author Message
stogner



Joined: 04 Feb 2009
Posts: 2

PostPosted: Thu Feb 05, 2009 2:55 pm    Post subject: retrieving value from a request object in radio button JSP Reply with quote

I am try to get value of radio button in next page through request getParameter but it is coming null instead of geting correct value

Code:
<form name="frm" action="page2.jsp">
<input type="radio" name="rdo" value="A"> A
<input type="radio" name="rdo" value="B"> B
<input type="radio" name="rdo" value="C"> C

<input type="submit" name="Submit">
</form>

but when I submit this page and use request.getparameter it is giving null

Quote:
String radioButton= request.getParameter("rdo");


this is not giving right value

Help need
Back to top
View user's profile Send private message
javatech



Joined: 19 Jan 2007
Posts: 39

PostPosted: Fri Feb 20, 2009 5:56 am    Post subject: Reply with quote

This is correct method to get value form radio button in JSP

What exactly problem you are getting.

http://www.easywayserver.com/blog/?p=16

It is also same procedure using as you and i execute code it is working fine here.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> Java,Struts framework, Velocity, JSF, Hibernate, Servlet, JSP, javaBeans All times are GMT
Page 1 of 1

 
Jump to:  
  Quick Post a Reply Topic
     
  Name (required)  
     
  Email Address (will not be published) (required)  
     
  Subject of topic (required)  
     
   
     
   
     
  Advertisement  
     
 
     


  More Links  
 
JSP Introduction
JSP Setup
Simple JSP Example
JSP Variable
Array Declaration in JSP
JSP Forms and User Input
Form Validation
JSP Cookies
JSP Session Object
Loop, content collection, iterator, conditional check in JSP
JSP Application Object
JSP Include
JSP Response Object
JSP Request Object
JSP Error Handling
JSP File Handling Object
JSP Action Tag
JSP Implicit Objects
JSP Declaration
JSP Directive
JDBC Introduction
JDBC Driver
JDBC Connection
JDBC Prepared/Statement
JDBC ResultSet
JDBC Close Connection object
JDBC Insert
JDBC Display Records
JDBC Update
JDBC Delete
JDBC Sorting
JDBC Query
JDBC Exception
JDBC Add Batch
JDBC Transaction/RollBack