You can do this using wildcard action mapping paths:
http://struts.apache.org/userGuide/building_controller.html#action_mapping_wildcards
L.
Brian Lalor wrote:
I'm working on a product catalog display application that uses the same
logic and code, but takes a common parameter for *every request*,
specifying the specific catalog to use. The application is a web
service of sorts, and has no state stored between requests.
I would like to use URLs of this schema and embed the catalog param in
the path:
http://host/root/CATALOG1/action.do
http://host/root/CATALOG2/action.do
I prefer this idea to specifying a request parameter (?catalog=1) for
every action.
I was thinking that I would somehow capture CATALOG1 and CATALOG2 and
stick them into the request, but I'm not sure how to go about it. It
this functionality that Struts already has, do I need to implement a
filter, or should I subclass the main ActionServlet?
Thanks in advance,
B
--
__ ____
/ / / __/ Brian Lalor "If you still have gas, you're not
lost."
/ _ \/__ \ [EMAIL PROTECTED] -- Jacques Strappe
/_.__/____/ http://bravo5.org/
--
Laurie, Open Source advocate, Java geek and novice blogger:
http://www.holoweb.net/~laurie/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]