Re: 404 from onActivate

2010-03-19 Thread Howard Lewis Ship
Actually, you can directly inject the Response object (the Response service is a shadow of RequestGlobals.response). On Fri, Mar 19, 2010 at 1:11 PM, Igor Drobiazko wrote: > Just inject service RequestGlobals [1] into your page, retrieve the Response > from it and send the 404 error to the client

Re: Reusable Component containing common parts of a form

2010-03-19 Thread Howard Lewis Ship
This is the kind of think that Block's are great at; you can have a parameter of type Block on your reusable component, and use in your template to include the Block's content at a specific point inside your component's template. It all just fits together at runtime. On Fri, Mar 19, 2010 at 2:58

Re: tapestry jumpstart without an editor (javax / compile problem)

2010-03-19 Thread Geoff Callender
The 3rd-party jars are not included because it can create licensing issues. Besides, this gives you a mechanism to update them really easily. Did you get JumpStart working in Eclipse with Jetty/OpenEJB before trying Tomcat? The Tomcat instructions have been tested by many people, but maybe you'

Re: Modifying the title in a layout component

2010-03-19 Thread Josh Canfield
You could do something like this: Layout.tml http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";> yadayada public class Layout { @Property private Block _head; @Property private Block _body; @Inject private ComponentResources _resources;

Re: 404 from onActivate

2010-03-19 Thread Kalle Korhonen
If you want Tapestry to render your error page, you need to configure the filter to handle error dispatches: app /* REQUEST ERROR Entirely possible that Jetty would route this to the app by default but I think it's o

Reusable Component containing common parts of a form

2010-03-19 Thread Liliana Liu
Hello, I am relatively new to Tapestry, am using 5.1.0.5 on a project, and hoping someone can help point me in the right direction. To reuse functionality for user signup to a web site, I have coded a custom component that contains a form that has the common fields and common processing in

Re: 404 from onActivate

2010-03-19 Thread Jan Jirout
Hi, I have same problem. I don't like solution with HTTP redirect to page that return 404 also. This solution is not fully logic from user perspective. I would like to by able to show error404 without any redirect. I have tried in onActivation method code: response.sendError(404, null); whe

Re: 404 from onActivate

2010-03-19 Thread Igor Drobiazko
Just inject service RequestGlobals [1] into your page, retrieve the Response from it and send the 404 error to the client. [1] http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/services/RequestGlobals.html On Fri, Mar 19, 2010 at 6:39 PM, Mike Oestereter wrote: > That's what I'm

Re: T5.2.0-SNAPHOT: newbie exceptions submitting form with BeanEditor

2010-03-19 Thread Joe Klecko
Thanks for all the responses. Switching to T5.1.5 fixed the problem. thanks, Joe buckofive wrote: > > Hi Joe/Howard, > > I have ran into this same problem a while back and oddly enough (just the > other day) I finally got around to filing a JIRA > (https://issues.apache.org/jira/browse/TAP5

Re: 404 from onActivate

2010-03-19 Thread Mike Oestereter
That's what I'm doing at the moment, but is not what I want. The result from the user's perspective is is a redirect 302 (or something) to a 404, which I don't think makes sense? On Fri, Mar 19, 2010 at 4:51 PM, Christian Riedel wrote: > I would create an Error404.java page and redirect to it in

Re: 404 from onActivate

2010-03-19 Thread Christian Riedel
I would create an Error404.java page and redirect to it in case your onActivate doesn't find a corresponding entity. Am 19.03.2010 um 15:04 schrieb Mike Oestereter: > Hello > > I've got a page that takes the context as parameter to produce a > result from db, e.g.: http:/hostname/app/page/123

Re: Invalid length 138 in LocalVariableTable

2010-03-19 Thread Yunhua Sang
Hi Jagadesh, use Javassist 3.9.0, the version 3.11.0 is not working well with Java 6 and Tapestry 5. On Fri, Mar 19, 2010 at 6:08 AM, Jagadesh Paladugula wrote: > Hi Every One, > > I am facing a wierd exception which says some thing like this > > *Invalid length 138 in LocalVariableTable in class

RE: tapestry jumpstart without an editor (javax / compile problem)

2010-03-19 Thread Acklen, Quincy L
Thanks, I didn't find those instructions. I added the proxypassword and proxyuser attributes and I was able to download the dependencies. (I really would have thought they would have included the required libs in zip OR a way to point them to the libs in the properties file to the location on you

404 from onActivate

2010-03-19 Thread Mike Oestereter
Hello I've got a page that takes the context as parameter to produce a result from db, e.g.: http:/hostname/app/page/123 If the db result for 123 does not exist I would like to throw a 404. Currently I'm using... Object onActivate(EventContext context) { //db lookup code to prepare page } I

Re: How to hook component into validation?

2010-03-19 Thread Michael Prescott
Joost, thanks for your help. Michael On Wed, Mar 17, 2010 at 8:27 PM, Joost Schouten (ml) wrote: > You can listen for the validation events on the individual form elements of > your component. > > eg: > > @Enviromental > private ValidationTracker validationTracker; > > @OnEvent(component = "myFo

Re: Resolving DTDs without an internet connection

2010-03-19 Thread Christophe Cordenier
Hi Contribute your DTD to the TemplateParserService : See this extract of core code : public static void contributeTemplateParser(MappedConfiguration config) { // Any class inside the internal module would do. Or we could move all these // files to o.a.t.services. Cl

Resolving DTDs without an internet connection

2010-03-19 Thread Klaus Kopruch
Hello * I want to use doctype http://www.wapforum.org/DTD/xhtml-mobile10.dtd";> in my tml files and have the problem in this case, that T5 cannot render the page because it cannot resolve the doctype. With doctype http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> I've no problem because th

Invalid length 138 in LocalVariableTable

2010-03-19 Thread Jagadesh Paladugula
Hi Every One, I am facing a wierd exception which says some thing like this *Invalid length 138 in LocalVariableTable in class file com/lp/ui/pages/system/parameter/ParameterTree* This exception comes when I have some complex operations in the page related class. If I move the complex logic to

Re: t5: properties files

2010-03-19 Thread Martin Strand
Don't know if I understand your question, but if you want to read .properties in UTF-8 format you can do this with JDK 6: new Properties().load(new InputStreamReader(yourInputStream, Charset.forName("UTF-8"))); On Fri, 19 Mar 2010 07:31:12 +0100, Angelo Chen wrote: Hi, As I understand,

Re: T5.2.0-SNAPHOT: newbie exceptions submitting form with BeanEditor

2010-03-19 Thread buckofive
Hi Joe/Howard, I have ran into this same problem a while back and oddly enough (just the other day) I finally got around to filing a JIRA (https://issues.apache.org/jira/browse/TAP5-1051). The only help/clue I can give to the T5 team is that the BeanEditor was working at one time in T5.2.0-SNAPS