Re: Using one component's value as input for the other

2011-04-14 Thread Martin Grigorov
If you use Wicket 1.5 then yet another approach is to use the events: http://wicketstuff.org/wicket/events/ On Thu, Apr 14, 2011 at 3:49 AM, Michael O'Cleirigh michael.ocleir...@rivulet.ca wrote: Another way is to pass down a common IModelString into both panels from a shared parent. Or to

Re: CryptedUrlWebRequestCodingStrategy and bookmarkable pages

2011-04-14 Thread Vitaly Tsaplin
Hi Igor, you can tweak the crypter to ignore bookmarkable urls. Well, that's what the crypter is supposed to do by default, isn't it? Now it simply tries to encrypt everything that starts with ? safely ignoring only RESTful urls. VItaly 2011/4/14 Igor Vaynberg igor.vaynb...@gmail.com: urls

Css url unexpected change

2011-04-14 Thread Tito
I have a page with an external css file wich is linked from html file. I mean, path is relative but hard. I guess wicket rewrite urls but here is the strange thing: I have a form with standar validation like a required field. I submit without adding information and all work, then again I click

Re: Css url unexpected change

2011-04-14 Thread Martin Grigorov
Either use absolute url, or context relative or use ResourceReference to setup it. Otherwise Wicket will try to fix it for you. On Thu, Apr 14, 2011 at 1:19 PM, Tito njyt...@gmail.com wrote: I have a page with an external css file wich is linked from html file. I mean, path is relative but

image in java script

2011-04-14 Thread fachhoch
I have a simple jquery function and it needs an image , right now I placed the image in webapp root and hadcoded the image path in jquery function including context root , please advice me how to use images in jquery functions ? -- View this message in context:

Re: Css url unexpected change

2011-04-14 Thread Tito
Yes, I know that wicket do that. But in my case wicket breaks it. Is it posible? 2011/4/14 Martin Grigorov mgrigo...@apache.org Either use absolute url, or context relative or use ResourceReference to setup it. Otherwise Wicket will try to fix it for you. On Thu, Apr 14, 2011 at 1:19 PM,

Re: Css url unexpected change

2011-04-14 Thread Martin Grigorov
Yes. By fix I meant that it will break it. Wicket tries to fix all relative urls. Since you don't use absolute (http://) or context relative one (/css/my.css) Wicket touches your resource url as well. On Thu, Apr 14, 2011 at 1:45 PM, Tito njyt...@gmail.com wrote: Yes, I know that wicket do

Re: Css url unexpected change

2011-04-14 Thread Tito
Sorry, I understood your expression. But, I mean if it is my mistake or could be a wicket bug... Because I can't see anything rare in the code. 2011/4/14 Martin Grigorov mgrigo...@apache.org Yes. By fix I meant that it will break it. Wicket tries to fix all relative urls. Since you don't use

Re: Css url unexpected change

2011-04-14 Thread Martin Grigorov
This is how Wicket works. You need to pick one of the options I enumerated in my first mail. On Thu, Apr 14, 2011 at 2:41 PM, Tito njyt...@gmail.com wrote: Sorry, I understood your expression. But, I mean if it is my mistake or could be a wicket bug... Because I can't see anything rare in the

Re: Css url unexpected change

2011-04-14 Thread Tito
Thanks! I solved it using another url mounting strategy. 2011/4/14 Martin Grigorov mgrigo...@apache.org This is how Wicket works. You need to pick one of the options I enumerated in my first mail. On Thu, Apr 14, 2011 at 2:41 PM, Tito njyt...@gmail.com wrote: Sorry, I understood your

Ajax Response and a Redirect, anyone seen this

2011-04-14 Thread Brown, Berlin [GCG-PFS]
https://gist.github.com/918794 Has anyone seen this, where is the code to process an ajax-response. POST /life/launch/?wicket: interface=:23:navigationPanel:nextLink::IActivePageBehaviorListener:1:-1 wicket:ignoreIfNotActive=truerandom=0.006311339758800216 HTTP/1.1 Accept: text/xml

Re: Ajax Response and a Redirect, anyone seen this

2011-04-14 Thread Martin Grigorov
the code is in wicket-ajax.js you Ajax callback lead to an error and thus the redirect to your internal error page On Thu, Apr 14, 2011 at 3:46 PM, Brown, Berlin [GCG-PFS] berlin.br...@primerica.com wrote: https://gist.github.com/918794 Has anyone seen this, where is the code to process an

RE: Ajax Response and a Redirect, anyone seen this

2011-04-14 Thread Brown, Berlin [GCG-PFS]
Where is the code to process the ajax-response, the java code? -Original Message- From: Martin Grigorov [mailto:mgrigo...@apache.org] Sent: Thursday, April 14, 2011 9:56 AM To: users@wicket.apache.org Subject: Re: Ajax Response and a Redirect, anyone seen this the code is in

Re: Ajax Response and a Redirect, anyone seen this

2011-04-14 Thread Martin Grigorov
AjaxRequestTarget creates it by default. Only when a redirect is needed ServletWebResponse creates it. On Thu, Apr 14, 2011 at 4:10 PM, Brown, Berlin [GCG-PFS] berlin.br...@primerica.com wrote: Where is the code to process the ajax-response, the java code? -Original Message- From:

Re: image in java script

2011-04-14 Thread Andrea Del Bene
Hi fachhoch, I had a similar problem with a custom date component (called JQueryDateField) which uses JQuery UI Datapicker. The problem was relative to the icon trigger next to the input field which should open Datapicker. When we initialize Datapicker we needs to know icon's URL, for

Re: image in java script

2011-04-14 Thread Pedro Santos
In a similar use case I assembled the JavaScript in an IHeaderContributor#renderHead implementation and written it in response using IHeaderResponse#renderOnDomReadyJavascript e.g.: class SetupDatepicker extends Behavior{ @Override public void renderHead(IHeaderResponse response) {

How to check if form submission succeeded using JavaScript?

2011-04-14 Thread Alec Swan
Hello, I have a button on a page which submits a Wicket form by calling form.submit() using straight JavaScript. If the form submitted without errors, then the JavaScript code should set a cookie. I am looking for some ideas on how to detect if the form was submitted successfully or not in

Re: How to check if form submission succeeded using JavaScript?

2011-04-14 Thread Pedro Santos
Hi, you can set a cookie in the Button#onSubmit implementation, new Button(){ public void onSubmit() { //at this point all validations are tested ((WebResponse)RequestCycle.get().getResponse()).addCookie(new Cookie(name, value)); } } On Thu, Apr 14, 2011 at 1:25 PM, Alec

Re: How to check if form submission succeeded using JavaScript?

2011-04-14 Thread Alec Swan
Thanks for the prompt response. However, in my case is has to be set on the client/JavaScript side because our application allows page designers to change the content of the page and its behavior at runtime and decide which cookie to set if any. Thanks, Alec On Thu, Apr 14, 2011 at 10:37 AM,

dynamic image loading issue with IE

2011-04-14 Thread kasim ahmed
I am using wicket framework. Issue is with dynamic image, it works fine with Firefox but the problem is with IE. i have method settimeout, images are laoding with dynamic action in IE and FF, but it is not going to next page. static private class SafeSubmitBehaviour extends

Re: dynamic image loading issue with IE

2011-04-14 Thread kasim ahmed
I have tried modifying set timeout by adding alert message as: alert(setTimeout('document.getElementById(\).append(component.getMarkupId()).append(\).submit()', 100)); it displays alert msg, then dynamic images are loaded ie animation is happeing then when user click ok for alert it stops

Re: How to check if form submission succeeded using JavaScript?

2011-04-14 Thread Martin Grigorov
if you use (JavaScript) form.submit() then this will reload the whole page. I.e. there is no way to do anything with JavaScript after submitting the form. On Thu, Apr 14, 2011 at 6:25 PM, Alec Swan alecs...@gmail.com wrote: Hello, I have a button on a page which submits a Wicket form by

Re: Refreshing loadable detachable model object inside an ajax call

2011-04-14 Thread Iain Reddick
Firstly, that LDM code is broken - calling detach() on load() makes no sense. Also, it will hit hibernate on every call to getObject(), as you aren't caching the loaded Parent entity. This is probably the cause of the hibernate exceptions you are seeing. Check out

Re: Refreshing loadable detachable model object inside an ajax call

2011-04-14 Thread lucast
Thank you, Iain. I shall try that. Cheers, Lucas -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Refreshing-loadable-detachable-model-object-inside-an-ajax-call-tp3446979p3450740.html Sent from the Users forum mailing list archive at Nabble.com.

Re: Refreshing loadable detachable model object inside an ajax call

2011-04-14 Thread Jeremy Thomerson
On Thu, Apr 14, 2011 at 3:51 PM, Iain Reddick iain.redd...@beatsystems.comwrote: Firstly, that LDM code is broken - calling detach() on load() makes no sense. Right - you should *not* call detach from within load(). Also, it will hit hibernate on every call to getObject(), as you aren't

Re: How to check if form submission succeeded using JavaScript?

2011-04-14 Thread Alec Swan
Thanks. I will follow yours and Pedro's recommendations and submit form using AjaxButton. On Thu, Apr 14, 2011 at 12:54 PM, Martin Grigorov mgrigo...@apache.org wrote: if you use (JavaScript) form.submit() then this will reload the whole page. I.e. there is no way to do anything with JavaScript

Re: Firefox 4: Modal windows redirect to invalid page, i.e WICKET-2207 in Firefox 4

2011-04-14 Thread Alec Swan
FYI, I had to disable Yahoo! Toolbar FireFox 4.0 add-on to get modal windows to work. On Mon, Apr 11, 2011 at 12:47 PM, Isammoc OFF isam...@gmail.com wrote: I agree with Matthias : FF4 for windows (under windows 7 x32) All ModalWindows work perfectly But a GET request for http://:/; is sent