Hi, I've started started working with JSP and are using Websphere Studio for
a development environment. The thing that is confusing me is that initially
I call a controller servlet which does my processing and setting bean
attributes. It then uses a callPage method to call a .servlet file(sort of
an XML file) that tells it the .JSP file to call and sets other attributes
such as database information, MQ Information, etc. My question is how to
get at the attributes that I set in the .servlet file?? Here's an example
of the servlet file.
This is the method that calls this file(the servlet and this file have to
have the same name) : callPage(getPageNameFromRequest(req), req, response);
I thought you could get at them calling the request.getParameter("db2admin")
method, but this is not working yet.
Any help would be greatly appreciated. Thanks
Example of .servlet file.
<?xml version="1.0"?><servlet>
<page-list>
<default-page>
<uri>/VitalServlets/MAS_One.jsp</uri> // this is the .jsp page
that is getting called
</default-page>
</page-list>
<code>com.Vital.VitalTest.MAS_One_JSP</code>
<init-parameter value="db2admin" name="userID"/> // these are the
attributes that I want to get at
<init-parameter value="db2admin" name="password"/>
<init-parameter value="jdbc:db2:SAMPLEDB" name="URL"/>
<init-parameter value="COM.ibm.db2.jdbc.app.DB2Driver" name="driver"/>
<init-parameter value="mqManager" name="VFLQMT1"/>
<init-parameter value ="mqQueue" name="VF.REQUEST"/>
</servlet>
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html