1. You would want to use tapestry's URL rewriting support to remove "whitelabelpartnerX" from the URL before passing it down the request processing pipeline.
2. As your URLRewriterRule removes the whitelabelpartner from the url, it should push it onto the Environment so that it can be accessed later. This can be done by @inject-ing the Environment and calling environment.push(new WhitelabelPartner(partnerValueFromUrl)); 3. Your layout component (and other pages / components) can then use the @Environmental annotation to get the WhitelabelPartner instance from the stack and style the page / provide priviledges accordingly Links http://tapestry.apache.org/url-rewriting.html http://tapestry.apache.org/request-processing.html http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/services/Environment.html http://tapestry.apache.org/environmental-services.html On Wednesday, 21 December 2011, captain_rhino < graeme.kitc...@axa-travel-insurance.com> wrote: > A little xmas cheer to all! > > I'm in the process of creating a white label site to handle insurance claims > for different partners. > > I'm looking for a general steer on how to handle the urls. > > The web page flow is generic for all the different white label partners. > > Currently external sites use the following links to access my site > www.mydomain.com/makeaclaim/whitelabelpartner1 > www.mydomain.com/makeaclaim/whitelabelpartner2 > > for a white label partner entering our site I use a > PageRenderLinkTransformer to then look at the that url and move them onto to > the start of the journey and store where they came from in the session. > i.e. move them from > www.mydomain.com/makeaclaim/whitelabelpartner1 > to > www.mydomain.com/makeaclaim/claimdetails > > > My problem is if they bookmark the claimsdetails or any future page links I > have no idea where they came from. I have thought of passing a request > parameter through the entire journey but that seems a bit clunky. > Ideally i'd like to be to do the following > > www.mydomain.com/makeaclaim/whitelabelpartner1/claimdetails > www.mydomain.com/makeaclaim/whitelabelpartner1/personaldetails > > www.mydomain.com/makeaclaim/whitelabelpartner2/claimdetails > www.mydomain.com/makeaclaim/whitelabelpartner2/personaldetails > > where claim details is one single tapestry page not placed in two separate > packages as this needs to be configurable as new partners can be added all > the time. > > Is some kind of url masking to page actions available in tapestry? > i.e. > www.mydomain.com/makeaclaim/*/claimdetails > > Any ideas/Suggestions welcome. > > -- > View this message in context: http://tapestry.1045711.n5.nabble.com/How-to-handle-urls-for-a-White-Label-site-tp5091687p5091687.html > Sent from the Tapestry - User mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > >