tapestry

Return non-HTML, non-JSON http bodies in Tapestry 5 ?

Hi, I have to implement the service provider of the OAuth protocol in a project that uses Tapestry5. Therefor I just need to return a very simple HTTP response body that is neither HTML or JSON. At first I tried to use the standard tml & pojo (java class, page) approach but this doesn't work because Tapestry tries to parse the template...

Form encoding in Tapestry

Hi ! I have a problem with Tapestry form. My XML database is very sensible with encoding, and need utf-8. When i put the char 'à' in my form, tapestry receive 'Ó' and my core get an error : Invalid byte 2 of 3-byte UTF-8 sequence. I haven't the problem in eclipse with local default configuration for tomcat. But whatever the tomcat co...

What's the approach to add javascript to a Tapestry application?

I'm starting with an existing webapp built with Tapestry. I can't figure out where to put the Javascript I need. Basically this application has a single page capturing data into a text area, and I want to include a javascript library to do something with that text area. What's the approach to add javascript to a Tapestry app? Any s...

Reusing page chunks in Tapestry 5

How can I re-use chunks of TML markup between pages? I want to refactor repetitive code out into a component, similar to a tag file or a jsp include. ...

How do I use Tapestry-Security ?

Hi, I discovered Tapestry 5, quite recently, its clear separation between view and controller, the use of name standardization instead of XML made me go for it straight. Quite frankly I don't plan on changing but the documentation is just not enough for me. The project I'm working on must be able to support several types of roles. I mu...

JasperReports not reading parameters properly?

Hi, I'm working on a web application written in Java using the Tapestry 5.1.0.5 framework. This framework does not have out-of-the-box support for JasperReports, so I wrote a service that modifies ChenilleKit's JasperReport service. I do not depend on the ChenilleKit version, instead I use the JasperReport 3.5.0 dependency. This may not...

Testing Tapestry pages and components with JUnit

I usually try to minimize testing with Selenium and maximize the usage of plain old back-end testing (JUnit, mocking). With Tapestry I am finding it hard to test pages and components in the latter way due to the "magic" that occurs with the callback functions. Have you been able to solve this? Or are you just using Selenium for the whol...

tapestry 4 table methods call multiple times

i do debug on IBasicTableModel , on method public IBasicTableModel getModel() { return new IBasicTableModel() { public int getRowCount() { //this is called multiple times } public Iterator getCurrentPageRows( int nFirst, int nPageSize, ITableColumn ...

How to create a multiple basket selection with Tapestry

Let's consider following problem. There is a page that contains baskets. A basket is a component that contains a list of items such as fruits or cars or whatever. In the page there are three baskets: car-basket, fruit-basket and all-basket. The car-basket contains cars, fruit-basket contains fruits and all-basket can contain both cars ...

How to print the year in a JSP?

I want to do something like this: <?php echo date('Y'); ?> But then in a .jsp file. All the tutorials I'm seeing require building a class somewhere. We're running appFuse and Tapestry. Surely one of those (if not Java itself) provide us with something to do this sort of thing without all that overhead. This seems like it should wor...

tapestry-hibernate and 2 databases

I have a Tapestry5.1 app using tapestry-hibernate which now needs to connect to a 2nd (separate, not redundant or load balanced) database. I've read that you can do this in hibernate by creating 2 separate session factories. I'm not sure how to configure this in tapestry-hibernate though. Any ideas? ...

Loop through a collection without a 'value' property in Tapestry

The Tapestry loop documentation shows the following example <t:loop source="pageNames" value="pageName"> <td class="${tabClass}"> <t:pagelink page="pageName">${pageName}</t:pagelink> </td> </t:loop> where the pageName variable is picked up from the Component: @Property private String _pageName; I...

Creating a form with a dynamic number of elements in Tapestry

I'm trying to generate a form with a variable - on the server side - number of text fields. The tapestry page looks similar to: <form t:id="form"> <t:loop source="typesOfIncome" value="typeOfIncome"> <input t:type="TextField" t:id="typeOfIncome-${typeOfIncome.propertyIndex}" value="100"/> </t:loop> </form> That is not...

Session Timeout AJAX Error in Tapestry Application

I'm building a webapp using Tapestry in combination with Spring Security and the jQuery-library besides Prototype. When a user clicks on a link after his session timed out, he is automatically redirected to the login page. This, of course, does not work for links, that trigger an AJAX-request. I know, this is a common problem with any k...

Reloading Tapestry layout and other components in development?

How can I make changes to tml files - like for layout and other components - quickly visible via F5 in the browser? At the moment I keep those files under the src/main/-folder next to the java class. I already tried to 'repackage' the file but it isn't picked up by Tapestry - it only works for tmls under /webapps. PS: Using IntelliJ wit...

Java Server Faces 2.0 or Tapestry 5.2?

Are there any up to date articles comparing JSF 2 and Tap 5? Everything I seem to find is comparing JSF 1.2 and Tap4. Does anyone have any experience with T5 or JSF2 and time to evangelize one or the other? I'm looking for a framework for rapid development in Java, on top of Hibernate and mySql. Other framework sales pitches accepted,...

Understanding Tapestry Principle 1. "Static Structure, Dynamic Behaviour"

I'm learning tapestry 5 web framework but I don't understand the principle 1 about it: "Static Structure, Dynamic Behaviour", what does means it ? If I don't add components to the components, how can I create a dynamic page? anyone can help me? Thanks in advance ...

Tapestry5 application not running on WTP Tomcat server

My Tapestry 5 application is running fine with a maven "tomcat:run" build, but not when I use a Tomcat WTP server. I.E: I created a tapestry 5 project based on the tapestry 5 quickstart maven archetype. At the beginning, it works fine with both servers. After playing a little bit with the dependencies (i.e. adding and then removing t...

What do you think about Tapestry 5.2?

I want to create a new project and I'm studing diferent web frameworks In StackOverFlow there are diferent threads of tapestry but it talks about Tapestry 4 or old Tapestry 5.0.8 What about tapestry 5.2, what do you think about it ? Thanks in advance ...