Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

request can not be resolved in jsp  RSS feed

 
srinivas peesabathula
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how to solve the problem of request can not be resolved in jsp?

in my program i wrote like this


EmpBean e1=(EmpBean)req.getParamater("res");


can any one help me
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65826
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You should not have any Java code in your JSP. Do request processing in a servlet.

If you do need to get at a request parameter in a JSP, you should be using the EL to do it. Java code in a JSP has been obsolete for a dozen years!
 
Stefan Evans
Bartender
Posts: 1834
10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The name of the implicit variable is "request" not "req"

Also, request parameters (note the spelling) can only be Strings.
Perhaps you are thinking about request attributes?


if there is a request attribute called "res" then ${res} would retrieve it.


 
srinivas peesabathula
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you for giving suggestion to Stefan Evans.finally i got the solution
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!