| Author |
problem in configuring servlet parameters to jsp
|
Prasanna RamKumar
Ranch Hand
Joined: Nov 30, 2005
Posts: 31
|
|
this is my part of web.xml file <servlet> <servlet-name>test</servlet-name> <jsp-file>/test2.jsp</jsp-file> <init-param> <param-name>email</param-name> <param-value>prasanna@genevasoftech.com</param-value> </init-param> <servlet-class>test</servlet-class> </servlet> but iam not able to get the parameters why this problem occurs
|
 |
Christophe Verré
Sheriff
Joined: Nov 24, 2005
Posts: 14672
|
|
|
Did you access the JSP file via its mapping (the servlet-mapping tag), or directly via the file name ? You have to use the mapping.
|
[My Blog]
All roads lead to JavaRanch
|
 |
Prasanna RamKumar
Ranch Hand
Joined: Nov 30, 2005
Posts: 31
|
|
yes now it is working after accesing through mapping thanks for your help prasanna
|
 |
Alexey Korneychuk
Greenhorn
Joined: Sep 06, 2005
Posts: 18
|
|
You are using BOTH <jsp-file>/test2.jsp</jsp-file> and <servlet-class>test</servlet-class>. It's wrong. The Strng dwe variable was declared in public void jspInit(). So You cannot use <%= dwe %>.
|
 |
Prasanna RamKumar
Ranch Hand
Joined: Nov 30, 2005
Posts: 31
|
|
then how i can print the value in that jsp page other than using implicit objects
|
 |
 |
|
|
subject: problem in configuring servlet parameters to jsp
|
|
|