Win a copy of Micro Frontends in Action this week in the Server-Side JavaScript and NodeJS forum!

Dhuruv Wadekar

Greenhorn
+ Follow
since Apr 07, 2008
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Dhuruv Wadekar

Yes I did....And it's working fine now.... thank you very much...Previously I didn't know that the reference of the URL must be given with respect to Root of that context

Thanks once again
12 years ago
JSP
Well Actually the index.jsp that i was talking about is the main jsp page with form controls that is trying to call the servlet. All I m trying to do is to include the operationType object in the request and forward it to the same page...
12 years ago
JSP
I use a web page with form controls on it. when the user clicks on submit, I try to transfer this information to a servlet. In the servlet I try to attach a value to the request and return it, using a request dispatcher like this.

RequestDispatcher dispatcher = getServletContext().getRequestDispatcher("http://www.xyz.com/Index.jsp");
req.setAttribute("operationType", operationType);
dispatcher.forward(req,res);


However my servlet returns a error :

java.lang.IllegalArgumentException: Path http://www.xyz.com/Index.jsp does not start with a "/" character


Can anyone help me resolve this issue?
12 years ago
JSP
Hello Everyone...

I am new to jsp and servlets and i need your help. I am in charge of developing a web application which does the following. There are three different frames that I need to handle. In one particular frame, there are a list of option buttons clicking on which I must present a list of sub options to the user. The user then selects a sub option and clicks on submit. Since I am totally new to all these I would request you to help me out in the following problems

1. I am trying to retrieve the sub options list from the server. I would like to know how this can be done based on the option selected by the user ( i can determine this through javascript).

2. How to send values to the servlet from a jsp page and vice versa.

3. How to call methods of a bean from a servlet (Includes get and set methods and also a few processing methods of the bean that take arguments).


I would be extremely glad if you can come forward and help me. I would also appreciate if you can share some related tutorials or articles.
12 years ago
JSP