File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSP and the fly likes Servlet and JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Servlet and JSP" Watch "Servlet and JSP" New topic

Servlet and JSP

Suresh Shah

Joined: Oct 29, 2003
Posts: 3
I have the following in web.xml.
<param-name> TheParam </param-name>
<param-value> ParamValue </param-value>
<description>The quick brown fox.</description>
using the following I am able to get all <param-name> and all <param-value> displayed in a JSP form.
<TABLE border cellspacing=0 cellpadding=5>
<th colspan=3 align=center>context.getInitParameter</th>
<th>Parameter Name</th>
for (Enumeration enu = application.getInitParameterNames();
enu.hasMoreElements() {
String x = (String)enu.nextElement();
temp = application.getInitParameter(x);
<td><%=x %></td>
<td><input text value= <%=temp %> ></td>
I need to be able to display <description> also. How do I do it?
Sri Basavanahally
Ranch Hand

Joined: Oct 07, 2003
Posts: 75
The description is not a parameter. If you want to display it, put it in as a parameter.

Bosun Bello
Ranch Hand

Joined: Nov 06, 2000
Posts: 1510
As posted by Sri, do this
<param-name> TheParam </param-name>
<param-value> ParamValue </param-value>
<param-name> description </param-name>
<param-value> The quick brown fox</param-value>

So much trouble in the world -- Bob Marley
I agree. Here's the link:
subject: Servlet and JSP
It's not a secret anymore!