the closest you can get to tapestry is a shared dynamic resource. you pass params much the same way - get a resource ref of the dynamic resource - construct a url for it using urlfor(resourceref) and then append any params you want - the resource then reads these params from the Request object. this is useful in situations where you need to feed data to the tags - like src attr of an img tag. there is a wiki article [1] (although somewhat convoluted with nonwicket stuff because it shows thumbnailing) that shows how to do this. here is the email thread with the discussion about the article and some other download related stuff [2].

another approach is to just stream the data out into the browser as a response to onclick or what not. this is useful when you want to create a download link. check out DownloadLink - it works with a file - but the concept can be easily generalized to retrieve the data from anywhere else. there is also a thread here [3]

[1] http://www.wicket-wiki.org.uk/wiki/index.php/UploadDownload
[2] http://www.nabble.com/Image-upload-tf1487150.html#a4194065
[3] http://www.nabble.com/Stream-Excel-to-the-client-tf1955606.html#a5363673

hope this gets you started

-Igor


On 8/22/06, spencer.c <[EMAIL PROTECTED] > wrote:

Hello all.  I'm coming from a Tapestry background, and I'm trying to
determine some similarities/differences between the two frameworks.  I think
I have my head around the basic application/page flow, but I have a question
regarding how I should plan to intergrate a dynamic download provider.

Example: A report generator which generates a pdf on the fly based upon
database records that were selected from a Wicket page.  How would I go
about constructing this?  Obviously I could just have a servlet and
construct the entire URL manually and link to it that way, but that isn't
very OO, and is not very elegant.  Tapestry has "services" which you can
instantiate and assign member variables to directly in you page's event
handler.  Is there an analagous feature in Wicket?  Or would you just
override some base page, even though it wouldn't be returning markup?

Thoughts on this are greatly appreciated.

Thanks in advance!

Spencer



--
View this message in context: http://www.nabble.com/How-to-link-to-dynamic-downloads-in-Wicket-app--tf2149647.html#a5936134
Sent from the Wicket - User forum at Nabble.com.


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to