Your questions are rather too specific to be of much use without the code
itself.
How are you making the call back to Wicket? Are you writing your own
AjaxBehavior?
If so, AbstractDefaultAjaxBehavior, which most of the Wicket AJAX
functionality extends, uses getCallbackScript(boolean) to generate the
wicketAjaxGet(...) bit of javascript. That function internally calls
getCallbackUrl(boolean). You can override this function in your behavior and
add some GET params on the end (return super.getCallbackUrl(...) +
"&foo=bar"). You can then retrieve these from your respond method with
RequestCycle.get().getRequest().getParameter("foo").
For some example code, see the list editor at http://londonwicket.org
Regards,
Alastair
On Tue, Apr 1, 2008 at 6:28 PM, Michael Mehrle <[EMAIL PROTECTED]>
wrote:
> I wrote a file uploader that works inside a Wicket modal window based on
> jQuery. Here's the original PHP based framework I based my work on:
>
> http://www.phpletter.com/Demo/AjaxFileUpload-Demo/
>
> It's up and running (took some tweaking to say the least), but I am
> still facing one hurdle:
>
> The file processing on the backend is done via a regular Wicket page.
> After verifying and saving the file it responds back with either an
> error or success JSON message that's sent back to my JavaScript function
> which originated the AJAX call. This way I can pop up alerts and advice
> the user if there are problems. So far so good.
>
> The problem I have is that I need to also bounce back the image id,
> since it needs to be further processed inside my Wicket panel. So, let's
> say I stick that id into my JSON message, and that it's available inside
> my JavaScript function that handles the success/failure function. What
> would be an elegant way to access that id from within Wicket? Again,
> remember that this whole image uploader is outside the Wicket framework.
> I would like to grab that id in my setCloseButtonCallback method after
> the modal has been closed.
>
> Any ideas would be greatly appreciated.
>
> Thanks!
>
> Michael
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>