Re: Absolute Asset URL 5.4

2014-09-11 Thread Lance Java
It's sometimes easy to forget that tapestry is just a normal war running in a servlet container. Assuming your building with maven, an image under src/main/webapp/foo.jpg will be available as http://myapp/foo.jpg On 11 Sep 2014 20:26, "George Christman" wrote: > Hi guys, I'm wondering if there

Re: absolute asset url

2010-10-04 Thread Josh Canfield
Have you looked into BaseURLSource? http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/services/BaseURLSource.html Overriding it is documented along with https but you can @Inject and use it elsewhere. http://tapestry.apache.org/tapestry5/guide/secure.html Josh 2010/9/30 Christian

Re: absolute asset url

2010-10-04 Thread Christian Köberl
The best thing is to have a setting (e.g. a Symbol) with the server url in it. Because with some configurations (e.g. with a load balancer in front) you cannot get the real server url via the HttpRequest. So your code would look something like this: @Inject @Path("context:/img/logo.gif") privat

Re: absolute asset url

2010-10-01 Thread Jonathan Barker
What is your use case? I need to have absolute URL's for an application and I contribute an override for the AssetPathConstructor. 2010/9/30 Christian Koller > Hi all > > In a tapestry page i have: > > @Inject > @Property > @Path("context:/img/logo.gif") > private Asset logo; > > If I print t