I think you have the include methods mixed up. The <%@ include> directive
does NOT allow you to use dynamic variables. If you want to access/share
variables between a jsp and an included file, then you must use
<jsp:include>.
If you access anything via an http://hostname/page.jsp url, then JRun
locates content relative to the Web server root, as you discovered. To keep
your jsps elsewhere, either create a virtual mapping in your Web server to a
directory other than the Web root, and then reference that mapping in your
code. Or, create an application in JRun, with an application mapping, and
then when you access that mapping in a url, JRun will find your jsps under
the root dir that you specify for that new application.
So, for example, you can create a new application (via the JMC) with an
application mapping of /newapp, and an application root dir of c:\mynewapp.
You can store all your jsps in this dir, and when you want to access that
application, you use the application mapping in the url; in this case,
http://hostname/newapp/whatever.jsp (whatever.jsp is located in
c:\mynewapp).
The jsp directory under WEB-INF is not for storing jsps, per se. That is
where JRun puts the servlets and related files that it generates when
accessing/translating a jsp.
HTH,
Patrick Quinn
Allaire Consulting
[EMAIL PROTECTED]
-----Original Message-----
From: Goyal, Gaurav (GEA, 097903) [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 18, 2000 11:10 AM
To: JRun-Talk
Subject: Pblm. with @Include
This is a problem that I am having with using the include directive. I
have a netscape enterprise server-jrun combo. I want to include a jsp
file(say jsp1) into another jsp(say jsp2). jsp1 also uses some of the
variables defined in jsp2. That is the reason why I want to use include
directive versus the jsp:include. The problem is that Jrun looks for the
included file in the netscape/server/docs directory(web server's root)
instead of the jsp directory that we have defined under Jrun. So how can I
make JRun look for the included file in our jsp directory rather than our
web server's root directory. Is there a setting of some sort which I need to
change in Jrun in order to accomplish this??
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community. http://www.fusionauthority.com/ads.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists