Re: Is there any way to render the "get" method of form?
Point us to the Jira Lutz, the HTML 2 specification details the following: "If the processing of a form is idempotent (i.e. it has no lasting observable effect on the state of the world), then the form method should be GET. Many database searches have no visible side-effects and make ideal applications of query forms." and: "If the service associated with the processing of a form has side effects (for example, modification of a database or subscription to a service), the method should be POST." so I believe you have a case. Cheers, Peter - Original Message - From: "Lutz Hühnken" To: "Tapestry users" Sent: Tuesday, 28 September, 2010 21:00:06 GMT +02:00 Athens, Beirut, Bucharest, Istanbul Subject: Re: Is there any way to render the "get" method of form? Dear Thiago, thanks for your patient reply and the advice. Of course I realize that I can still implement a search with Tapestry, with redirect-after-post or else, and I have actually done so in the past. But please take a minute and think about these two things: 1. You say, > GET was always meant to be used in request that don't change the state of > the application (including database) and this is exactly what I would like to use it for - as I said, a search. You could re-phrase your argument: "POST was meant for requests that do change the state." So why do I have to use it for requests that do not? 2. Of course, a lot of things are doable, change the DOM and what not. But wasn't the idea of Tapestry "make the simple things easy, the difficult things possible"? A form with method=get is totally valid HTML, and I think it should be easy, not complicated. These two reasons are why I said the lack of get-forms is "puzzling" me, it just seems somewhat inconsistent with the rest of Tapestry (which I use and will continue to use with great pleasure). I did as you told me and created a JIRA ticket (a "wish") for it: "https://issues.apache.org/jira/browse/TAP5-1285"; Keep up the good work, Lutz -- altocon GmbH http://www.altocon.de/ Software Development, Consulting Hamburg, Germany - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5: Easy FckEditor in Form with associated Zone
Ville, thank you. Ticket opend : http://kenai.com/jira/browse/T5_EASY_FCKEDITOR-4 Peter Hi, I will take a look at the old FCK editor (The main effort has been put to the newer CK integration.) to make it compatible with 5.2. I'll take a look at this also, but unfortunately it will take 2-4 weeks, as I'm a bit busy now. I suspect that the AJAX submit breaks the editor default logic that handles the "value from editor to underlaying textfield" process - so the probable answer is to register some T5 event listener that does this instead. - Ville Ps. Please open a JIRA ticket for this in http://kenai.com/jira/browse/T5_EASY_FCKEDITOR - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Early steps getting Tapestry and Hibernate working via DAO
https://bitbucket.org/mgruca/tjug_tapestry_30.09.10/downloads That should run in eclipse with m2 plugin. Check it out, maybe it will help to find solution. In case if revision 9 wouldn't work, try previous one. Rev 9 are changes that I made during presentation, they should not affect anything, but I prefer to mention it just in case.a With regards Michał Gruca Alex W. Croton wrote: > > Hi, > > I am a real newbie when it comes to Tapestry and even worse than that when > it comes to Hibernate. > > I am using Tapestry 5.1.0 and Hibernate 3.3.1 - talking to a MySQL > database. > > I've got the code from the Tapestry5HowToUseTapestryHibernate working > fine, but in the application that I am putting together I want/need to be > able to use DAO to interface between the various components of the > application. > > After 3 days of various Googling, I'm far more confused than when I > started - it seems that the examples that I have been able to find are > either for a different version of Tapestry - or appear to be using some > form of magic that my environment is lacking :-) > > Can anyone offer any pointers to get me going on what 'bits' I need where > please? > > Regards, > > Alex C > > -- View this message in context: http://tapestry-users.832.n2.nabble.com/Early-steps-getting-Tapestry-and-Hibernate-working-via-DAO-tp5591178p5601938.html Sent from the Tapestry Users 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
Re: [T5.2] Principle 1, Static Structure Dynamic Behaviour
Hi, thank you for the response So I don't understand the principle 1. What happend if I add a html element in the tree dom and I get the value from the request after submit ? I'm violating the principle? Is there a problem if I do that? -- View this message in context: http://tapestry.1045711.n5.nabble.com/T5-2-Principle-1-Static-Structure-Dynamic-Behaviour-tp3198357p3198857.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
Re: Dynamically loading a component
This is horrible news since I have no way of knowing the components that needs to be called at design time (other wise I would use a ). There is no magic that can be done to achieve this at all? Even if I have to use the internal services. Thanks for your quick response. Omar On Oct 4, 2010, at 18:41, "Thiago H. de Paula Figueiredo" wrote: > On Mon, 04 Oct 2010 19:35:38 -0300, Omar Carvajal > wrote: > >> Hey all, > > Hi! > >> I am trying to dynamically load a component which must be determined at >> run time, I figured I must use a t:delegate to render the component. >> On the Java side of things I cannot figure out how to instantiate the >> actual component. I saw the @Component annotation with the "type" parameter >> but this does not let me dynamically load a component from a function. >> Does anybody have any idea on how to do this? > > Declare the components inside a . are not rendered unless > you pass it to a Delegate or return it to update a Zone. You cannot > instantiate components in Java code, as Tapestry is static structure, dynamic > behavior (including rendering). Take a look at > http://tapestry.apache.org/tapestry5.1/cookbook/switch.html. It shows you how > to render blocks dynamically, but the same approach can be used for > components as well. You'll use @InjectComponent to get access in your Java > code to the component instances declared in templates. > > -- > Thiago H. de Paula Figueiredo > Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and > instructor > Owner, Ars Machina Tecnologia da Informação Ltda. > http://www.arsmachina.com.br > > - > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Dynamically loading a component
On Mon, 04 Oct 2010 19:35:38 -0300, Omar Carvajal wrote: Hey all, Hi! I am trying to dynamically load a component which must be determined at run time, I figured I must use a t:delegate to render the component. On the Java side of things I cannot figure out how to instantiate the actual component. I saw the @Component annotation with the "type" parameter but this does not let me dynamically load a component from a function. Does anybody have any idea on how to do this? Declare the components inside a . are not rendered unless you pass it to a Delegate or return it to update a Zone. You cannot instantiate components in Java code, as Tapestry is static structure, dynamic behavior (including rendering). Take a look at http://tapestry.apache.org/tapestry5.1/cookbook/switch.html. It shows you how to render blocks dynamically, but the same approach can be used for components as well. You'll use @InjectComponent to get access in your Java code to the component instances declared in templates. -- Thiago H. de Paula Figueiredo Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor Owner, Ars Machina Tecnologia da Informação Ltda. http://www.arsmachina.com.br - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Dynamically loading a component
Hey all, I am trying to dynamically load a component which must be determined at run time, I figured I must use a t:delegate to render the component. On the Java side of things I cannot figure out how to instantiate the actual component. I saw the @Component annotation with the "type" parameter but this does not let me dynamically load a component from a function. Does anybody have any idea on how to do this? Thanks, Omar - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [T5.2, Google Application Engine] Can't get a method to be realized (i.e. invoke a method)
On Mon, 04 Oct 2010 18:29:26 -0300, Muhammad Mohsen wrote: Hi All, Hi! I strongly suggest you to try to make your application work on Jetty or Tomcat first, specially if you're still learning Tapestry, and after that try the GAE, as it is a different environment. -- Thiago H. de Paula Figueiredo Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor Owner, Ars Machina Tecnologia da Informação Ltda. http://www.arsmachina.com.br - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [T5.2] Principle 1, Static Structure Dynamic Behaviour
The documentation is in flux, but I actually just re-wrote that section of the docs... feedback is welcome. https://cwiki.apache.org/confluence/display/TAPESTRY/Principles Static structure referred to page pooling a lot, but it's really more than that. Josh On Mon, Oct 4, 2010 at 1:29 PM, iberck wrote: > > Hi forum, > > I have a question, > > since T5.2 does't use a pages pool, what happend with Tapestry principle 1? > Now, can we have a more flexible component framework? :) > > > -- > View this message in context: > http://tapestry.1045711.n5.nabble.com/T5-2-Principle-1-Static-Structure-Dynamic-Behaviour-tp3198357p3198357.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 > > -- -- http://www.bodylabgym.com - a private, by appointment only, one-on-one health and fitness facility. -- http://www.ectransition.com - Quality Electronic Cigarettes at a reasonable price! -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: [T5.2] Principle 1, Static Structure Dynamic Behaviour
On Mon, 04 Oct 2010 17:29:36 -0300, iberck wrote: Hi forum, Hi! I have a question, since T5.2 does't use a pages pool, what happend with Tapestry principle 1? It stays the same. The difference is that there's only one instance for every page. Now, can we have a more flexible component framework? :) We have a very flexible component framework. :) You only need to think some scenarios in a little different way. -- Thiago H. de Paula Figueiredo Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor Owner, Ars Machina Tecnologia da Informação Ltda. http://www.arsmachina.com.br - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
[T5.2] Principle 1, Static Structure Dynamic Behaviour
Hi forum, I have a question, since T5.2 does't use a pages pool, what happend with Tapestry principle 1? Now, can we have a more flexible component framework? :) -- View this message in context: http://tapestry.1045711.n5.nabble.com/T5-2-Principle-1-Static-Structure-Dynamic-Behaviour-tp3198357p3198357.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
Re: @Cached method called multiple times
On Mon, 04 Oct 2010 14:18:19 -0300, Tobias Marx wrote: Hello everyone! Hi! I am using Tapestry 5.1.5 and I noticed that a method annotated as @Cached is executed several times for a single pageview. I am using a "BaseComponent" class that contains this method. It is called from component that extends this. I guess you have more than one BaseComponent subclass instance in your page. If so, you're seeing the expected behavior. -- Thiago H. de Paula Figueiredo Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor Owner, Ars Machina Tecnologia da Informação Ltda. http://www.arsmachina.com.br - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
@Cached method called multiple times
Hello everyone! I am using Tapestry 5.1.5 and I noticed that a method annotated as @Cached is executed several times for a single pageview. I am using a "BaseComponent" class that contains this method. It is called from component that extends this. Or is it possible @Cached is not working when debugging with Jetty? Thanks! Tobias - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: absolute asset url
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 Koller : > Hi all > > In a tapestry page i have: > > @Inject > @Property > @Path("context:/img/logo.gif") > private Asset logo; > > If I print the logo I can see: > /assets/7f46afe50e4fd75d/ctx/img/logo.gif > > What I need is an absolute url from the logo (e.g: > http://localhost:8080/assets/7f46afe50e4fd75d/ctx/img/logo.gif). Is that > possible without to use the request. > I mean is there a better way as to fetch the host and port from the request > and then to concatenate the stuff. > > Thx > chris > > > -- -- http://www.bodylabgym.com - a private, by appointment only, one-on-one health and fitness facility. -- http://www.ectransition.com - Quality Electronic Cigarettes at a reasonable price! -- TheDailyTube.com. Sign up and get the best new videos on the internet delivered fresh to your inbox. - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: T5: Easy FckEditor in Form with associated Zone
Hi, I will take a look at the old FCK editor (The main effort has been put to the newer CK integration.) to make it compatible with 5.2. I'll take a look at this also, but unfortunately it will take 2-4 weeks, as I'm a bit busy now. I suspect that the AJAX submit breaks the editor default logic that handles the "value from editor to underlaying textfield" process - so the probable answer is to register some T5 event listener that does this instead. - Ville Ps. Please open a JIRA ticket for this in http://kenai.com/jira/browse/T5_EASY_FCKEDITOR -- View this message in context: http://tapestry.1045711.n5.nabble.com/T5-Easy-FckEditor-in-Form-with-associated-Zone-tp3173118p3176544.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
[t5] Problems with grid in a loop
Hi, On a page i have a grid in a loop. When inPlace="true" clicking on a grids Pager-link always results in displaying the content of the last edited grid on the page, so i`m not able to move through the pages of the grids, and all grids display same information after clicking eachs grid-page-link. I assign unique id`s to each grid in the loop, but a look at the generated html reveals, that the id are assigned to the table of the grid, not to the sourroundig div. Is there a way to use grids in loops while inPlace=true? Thanks Peter - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Custom coercion from String to Long
Actually, you can't decorate TypeCoercer, so you are basically out of luck. However, since you are talking about encoding and decoding data in URLs and query parameters, you can work with the ValueEncoderSource instead! It has a more flexible, more forgiving configuration. On Mon, Oct 4, 2010 at 1:51 AM, Christian Köberl wrote: > > The problem is that Tapestry itself is already adding this Coercion: > > TapestryIOCModule: > add(configuration, String.class, Long.class, new Coercion Long>() > { > public Long coerce(String input) > { > return new Long(input); > } > }); > > So, the only possible way is to decorate (override) the TypeCoercer and > return your implementation on coerce. > -- > View this message in context: > http://tapestry-users.832.n2.nabble.com/Custom-coercion-from-String-to-Long-tp5582965p5598307.html > Sent from the Tapestry Users 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 > > -- Howard M. Lewis Ship Creator of Apache Tapestry The source for Tapestry training, mentoring and support. Contact me to learn how I can get you up and productive in Tapestry fast! (971) 678-5210 http://howardlewisship.com - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
Re: Custom coercion from String to Long
The problem is that Tapestry itself is already adding this Coercion: TapestryIOCModule: add(configuration, String.class, Long.class, new Coercion() { public Long coerce(String input) { return new Long(input); } }); So, the only possible way is to decorate (override) the TypeCoercer and return your implementation on coerce. -- View this message in context: http://tapestry-users.832.n2.nabble.com/Custom-coercion-from-String-to-Long-tp5582965p5598307.html Sent from the Tapestry Users 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
Re: absolute asset url
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") private Asset logo; @Value("server.url") private String serverUrl public String getLogoUrl() { return serverUrl + logo.toClientURL(); } Cheers, another Chris PS: you can also add your own binding prefix "absolute:" but that needs some more work. -- View this message in context: http://tapestry-users.832.n2.nabble.com/absolute-asset-url-tp5588296p5599216.html Sent from the Tapestry Users 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
T5: Easy FckEditor in Form with associated Zone
Hi all, We are using t5-easyFckEditor quite a while and it runs very well. But now we try to use it within a form with an associated zone. As soon as Zone="xyZone" is included in the - tag the content of the editorfield is not submitted (or not associated to the value-field) when the user submits the form (all other fields work fine). But when the user submits the form _again_, the value entered _before the first submit_ is set to the value-field. System is tapestry 5.1.0.5 and t5-easy-fckeditor-1.0.4 Has anybody faced the same problem or a tip how to solve it? Thanks Peter - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org
absolute asset url
I have to use an external image scale service and this service needs an absolute url, the service can't work with a relative url. On 02.10.2010, at 04:33, Jonathan Barker wrote: > 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 the logo I can see: >> /assets/7f46afe50e4fd75d/ctx/img/logo.gif >> >> What I need is an absolute url from the logo (e.g: >> http://localhost:8080/assets/7f46afe50e4fd75d/ctx/img/logo.gif). Is that >> possible without to use the request. >> I mean is there a better way as to fetch the host and port from the request >> and then to concatenate the stuff. >> >> Thx >> chris >> >> >> > > > -- > Jonathan Barker > ITStrategic - To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org