You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Ben Gidley <be...@gidley.co.uk> on 2009/06/29 10:58:09 UTC

POST request for tapestry ajax requests

Hi,

I am looking at extending tapestry-cacheControl (hosted at
tapestry.formos.com) to work with AJAX requests - currently tapestry uses
POST for all AJAX requests - which effectively prevents caching them. I can
see a number of scenario's where it would be handy to be able to cache them
(e.g. a type ahead search).

I am currently trying to think of a good way to enable this. As far as I can
see there are a few options

   - Change/override tapestry.js to use GET instead of POST. The hazard of
   this is wrongly configured cache control headers will cause un-expected
   results so it may not be fully back compatible.
   - Extend tapestry.js and links so they can set the method to GET/POST for
   an AJAX request

Has anyone got any ideas of an easier way of doing this?


Thanks

Ben Gidley

www.gidley.co.uk
ben@gidley.co.uk