lloyd wrote:
(...)
i have the opportunity, an unrelated question (which may stem from my conception of contexts as isolated applications): in servlets, is it possible (or even desirable) to have paths interpreted relative to the context root?

eg, using the example above, when i reference a cheetah template i have to do something like this:

  template = Template(file="inventory/stock-levels.tmpl")

this feels awkward to me - again, perhaps because i think that the context is the application root, and therefore the application shouldn't have to know the name of the directory that its files are in.

for this specific task you may want to experiment with Application.serverSidePath (resolves relative paths from
the *application* root), Page.serverSidePath (resolves relative paths from the current servlet), Request.serverSideContextPath and Request.contextName.





------------------------------------------------------- This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting Tool for open source databases. Create drag-&-drop reports. Save time by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc. Download a FREE copy at http://www.intelliview.com/go/osdn_nl _______________________________________________ Webware-discuss mailing list Webware-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/webware-discuss

Reply via email to