Re: Unable to close ModalWindow 1.4.1
For cross (sub) domain reasons - I am adding document.domain to my page. can't you access your application with http://subdomain.domain.com:8080 at first place? if no, see if you can reach this effect with: http://wicket.apache.org/docs/1.4/org/apache/wicket/request/IRequestCodingStrategy.html at the javadoc says: creating url representations for request targets On Tue, Sep 15, 2009 at 11:17 PM, Ed _ wrote: > > For cross (sub) domain reasons - I am adding document.domain to my page. > > > > Is there a way to make modalwindow / Wickets Ajax links to work with it? > > > > thx > > > From: ed_b...@hotmail.com > > To: users@wicket.apache.org > > Subject: RE: Unable to close ModalWindow 1.4.1 > > Date: Tue, 15 Sep 2009 18:49:03 -0700 > > > > > > > > > > Permission denied for <http://domain.com> to get property Window.Wicket > from <http://subdomain.domain.com:8080>. > > > http://subdomain.domain.com:8080/?wicket:interface=modal-dialog-pagemap:15:: > :: > > Line 265 > > > > wonder why it thinks that the domains are different ? > > > > can I force domain.doc value somehow > > > > thx > > > > > Date: Tue, 15 Sep 2009 21:45:34 -0300 > > > Subject: Re: Unable to close ModalWindow 1.4.1 > > > From: pedros...@gmail.com > > > To: users@wicket.apache.org > > > > > > - I get permission denied exception as reported by firebug. > > > - head section with my javascript > > > > > > The firebug firefox plugging has an javascript console. Execute on him > ( > > > maybe you will not to get permission denied here): > > > alert(Wicket.Window.current) > > > alert(window.parent.Wicket.Window.current) > > > at the end of the javascript operations you report: > > > > > > "At the end of the operations I hide all the divs and then show a div > that > > > has a "close link"" > > > > > > and let us to know what value then have. > > > > > > call the alerts to output the values, > > > > > > On Tue, Sep 15, 2009 at 9:13 PM, Ed _ wrote: > > > > > > > > > > > Thanks for the suggestion. > > > > > > > > I have been using close(target) - unfortunately attached a run when I > was > > > > using both methods. Even with one ajax response appended it doesn't > work. > > > > > > > > New to JS - can you tell me how to test the variables. If I add > > > > > > > > var status = window.parent.Wicket.Window; as part of my JS - I get > > > > permission denied exception as reported by firebug. > > > > > > > > > > > > My html file includes a head section with my javascript and the > markup has > > > > wicket elements viz where the close links are rendered. I have two > such > > > > links - both of which are rendered useless when used in this > configuration - > > > > although the main close button of the modalwindow continues to work. > > > > > > > > thanks > > > > > > > > > Date: Tue, 15 Sep 2009 18:00:47 -0300 > > > > > Subject: Re: Unable to close ModalWindow 1.4.1 > > > > > From: pedros...@gmail.com > > > > > To: users@wicket.apache.org > > > > > > > > > > by close(target) or ModalWindow.close(target) > > > > > --> use close(target), to maintain ModalWindow internal states > updated. > > > > > > > > > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos > > > > > wrote: > > > > > > > > > > > On this ajax response, we can see that the close script was > appended 2 > > > > > > times. Make sure that it appended only once, by close(target) or > > > > > > ModalWindow.close(target). > > > > > > Before click the "close link", in a moment that was causing > trouble, > > > > see if > > > > > > these variables are not null: > > > > > > > > > > > > Wicket.Window.current > > > > > > window.parent.Wicket.Window.current > > > > > > > > > > > > If so, look at what moment they are nullified. The close method > called > > > > on > > > > > > response: > > > > > > win.current.close() > > > > > > depends on these variables. > > > > > > > > > > > > > > &
RE: Unable to close ModalWindow 1.4.1
For cross (sub) domain reasons - I am adding document.domain to my page. Is there a way to make modalwindow / Wickets Ajax links to work with it? thx > From: ed_b...@hotmail.com > To: users@wicket.apache.org > Subject: RE: Unable to close ModalWindow 1.4.1 > Date: Tue, 15 Sep 2009 18:49:03 -0700 > > > > > Permission denied for <http://domain.com> to get property Window.Wicket from > <http://subdomain.domain.com:8080>. > http://subdomain.domain.com:8080/?wicket:interface=modal-dialog-pagemap:15 > Line 265 > > wonder why it thinks that the domains are different ? > > can I force domain.doc value somehow > > thx > > > Date: Tue, 15 Sep 2009 21:45:34 -0300 > > Subject: Re: Unable to close ModalWindow 1.4.1 > > From: pedros...@gmail.com > > To: users@wicket.apache.org > > > > - I get permission denied exception as reported by firebug. > > - head section with my javascript > > > > The firebug firefox plugging has an javascript console. Execute on him ( > > maybe you will not to get permission denied here): > > alert(Wicket.Window.current) > > alert(window.parent.Wicket.Window.current) > > at the end of the javascript operations you report: > > > > "At the end of the operations I hide all the divs and then show a div that > > has a "close link"" > > > > and let us to know what value then have. > > > > call the alerts to output the values, > > > > On Tue, Sep 15, 2009 at 9:13 PM, Ed _ wrote: > > > > > > > > Thanks for the suggestion. > > > > > > I have been using close(target) - unfortunately attached a run when I was > > > using both methods. Even with one ajax response appended it doesn't work. > > > > > > New to JS - can you tell me how to test the variables. If I add > > > > > > var status = window.parent.Wicket.Window; as part of my JS - I get > > > permission denied exception as reported by firebug. > > > > > > > > > My html file includes a head section with my javascript and the markup has > > > wicket elements viz where the close links are rendered. I have two such > > > links - both of which are rendered useless when used in this > > > configuration - > > > although the main close button of the modalwindow continues to work. > > > > > > thanks > > > > > > > Date: Tue, 15 Sep 2009 18:00:47 -0300 > > > > Subject: Re: Unable to close ModalWindow 1.4.1 > > > > From: pedros...@gmail.com > > > > To: users@wicket.apache.org > > > > > > > > by close(target) or ModalWindow.close(target) > > > > --> use close(target), to maintain ModalWindow internal states updated. > > > > > > > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos > > > wrote: > > > > > > > > > On this ajax response, we can see that the close script was appended 2 > > > > > times. Make sure that it appended only once, by close(target) or > > > > > ModalWindow.close(target). > > > > > Before click the "close link", in a moment that was causing trouble, > > > see if > > > > > these variables are not null: > > > > > > > > > > Wicket.Window.current > > > > > window.parent.Wicket.Window.current > > > > > > > > > > If so, look at what moment they are nullified. The close method called > > > on > > > > > response: > > > > > win.current.close() > > > > > depends on these variables. > > > > > > > > > > > > > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > > > > > > > >> > > > > >> > > > > >> Looking for hints to debug the situation I am in. Thanks. > > > > >> > > > > >> Using wickets 1.4.1 > > > > >> > > > > >> I have tried a simple scenario - opening a page in a modal window > > > > >> and > > > > >> then using a link in the page to close the window. Works fine. > > > > >> > > > > >> Now I am opening a more complicated page with its own javascript - > > > > >> performing a bunch of operations on that page using js while it is > > > opened in > > > > >> a modal window. At the end of the operations I hide all the divs and > > > then > > > &g
RE: Unable to close ModalWindow 1.4.1
Permission denied for <http://domain.com> to get property Window.Wicket from <http://subdomain.domain.com:8080>. http://subdomain.domain.com:8080/?wicket:interface=modal-dialog-pagemap:15 Line 265 wonder why it thinks that the domains are different ? can I force domain.doc value somehow thx > Date: Tue, 15 Sep 2009 21:45:34 -0300 > Subject: Re: Unable to close ModalWindow 1.4.1 > From: pedros...@gmail.com > To: users@wicket.apache.org > > - I get permission denied exception as reported by firebug. > - head section with my javascript > > The firebug firefox plugging has an javascript console. Execute on him ( > maybe you will not to get permission denied here): > alert(Wicket.Window.current) > alert(window.parent.Wicket.Window.current) > at the end of the javascript operations you report: > > "At the end of the operations I hide all the divs and then show a div that > has a "close link"" > > and let us to know what value then have. > > call the alerts to output the values, > > On Tue, Sep 15, 2009 at 9:13 PM, Ed _ wrote: > > > > > Thanks for the suggestion. > > > > I have been using close(target) - unfortunately attached a run when I was > > using both methods. Even with one ajax response appended it doesn't work. > > > > New to JS - can you tell me how to test the variables. If I add > > > > var status = window.parent.Wicket.Window; as part of my JS - I get > > permission denied exception as reported by firebug. > > > > > > My html file includes a head section with my javascript and the markup has > > wicket elements viz where the close links are rendered. I have two such > > links - both of which are rendered useless when used in this configuration - > > although the main close button of the modalwindow continues to work. > > > > thanks > > > > > Date: Tue, 15 Sep 2009 18:00:47 -0300 > > > Subject: Re: Unable to close ModalWindow 1.4.1 > > > From: pedros...@gmail.com > > > To: users@wicket.apache.org > > > > > > by close(target) or ModalWindow.close(target) > > > --> use close(target), to maintain ModalWindow internal states updated. > > > > > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos > > wrote: > > > > > > > On this ajax response, we can see that the close script was appended 2 > > > > times. Make sure that it appended only once, by close(target) or > > > > ModalWindow.close(target). > > > > Before click the "close link", in a moment that was causing trouble, > > see if > > > > these variables are not null: > > > > > > > > Wicket.Window.current > > > > window.parent.Wicket.Window.current > > > > > > > > If so, look at what moment they are nullified. The close method called > > on > > > > response: > > > > win.current.close() > > > > depends on these variables. > > > > > > > > > > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > > > > > >> > > > >> > > > >> Looking for hints to debug the situation I am in. Thanks. > > > >> > > > >> Using wickets 1.4.1 > > > >> > > > >> I have tried a simple scenario - opening a page in a modal window and > > > >> then using a link in the page to close the window. Works fine. > > > >> > > > >> Now I am opening a more complicated page with its own javascript - > > > >> performing a bunch of operations on that page using js while it is > > opened in > > > >> a modal window. At the end of the operations I hide all the divs and > > then > > > >> show a div that has a "close link" > > > >> > > > >> The link does not close the modal window - I see the request coming to > > the > > > >> server I call close(target) tried ModalWindow.close(target) too but > > nothing > > > >> happens. > > > >> > > > >> The window closes with the X close button on the top right. > > > >> > > > >> the wicket debug shows the operation / at least being able to fetch > > the > > > >> code to shut the window down succeeding . > > > >> > > > >> > > > >> > > http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 > > > >> > > > >> > > >> encoding="UTF-8"?> > > > >> > > > >> _ > > > >> Hotmail: Free, trusted and rich email service. > > > >> http://clk.atdmt.com/GBL/go/171222984/direct/01/ > > > >> > > > > > > > > > > > > _ > > Bing brings you health info from trusted sources. > > > > http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1 _ Bing brings you health info from trusted sources. http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1
RE: Unable to close ModalWindow 1.4.1
Ok I added this to the html alert(window.parent.Wicket.Window.current); of my simple page example and the alert poped up with [object Object] When I add it to my actual page - I get permission denied. :( alert(Wicket.Window.current) - shows up as an error - undefined in the test page. Thanks > Date: Tue, 15 Sep 2009 21:45:34 -0300 > Subject: Re: Unable to close ModalWindow 1.4.1 > From: pedros...@gmail.com > To: users@wicket.apache.org > > - I get permission denied exception as reported by firebug. > - head section with my javascript > > The firebug firefox plugging has an javascript console. Execute on him ( > maybe you will not to get permission denied here): > alert(Wicket.Window.current) > alert(window.parent.Wicket.Window.current) > at the end of the javascript operations you report: > > "At the end of the operations I hide all the divs and then show a div that > has a "close link"" > > and let us to know what value then have. > > call the alerts to output the values, > > On Tue, Sep 15, 2009 at 9:13 PM, Ed _ wrote: > > > > > Thanks for the suggestion. > > > > I have been using close(target) - unfortunately attached a run when I was > > using both methods. Even with one ajax response appended it doesn't work. > > > > New to JS - can you tell me how to test the variables. If I add > > > > var status = window.parent.Wicket.Window; as part of my JS - I get > > permission denied exception as reported by firebug. > > > > > > My html file includes a head section with my javascript and the markup has > > wicket elements viz where the close links are rendered. I have two such > > links - both of which are rendered useless when used in this configuration - > > although the main close button of the modalwindow continues to work. > > > > thanks > > > > > Date: Tue, 15 Sep 2009 18:00:47 -0300 > > > Subject: Re: Unable to close ModalWindow 1.4.1 > > > From: pedros...@gmail.com > > > To: users@wicket.apache.org > > > > > > by close(target) or ModalWindow.close(target) > > > --> use close(target), to maintain ModalWindow internal states updated. > > > > > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos > > wrote: > > > > > > > On this ajax response, we can see that the close script was appended 2 > > > > times. Make sure that it appended only once, by close(target) or > > > > ModalWindow.close(target). > > > > Before click the "close link", in a moment that was causing trouble, > > see if > > > > these variables are not null: > > > > > > > > Wicket.Window.current > > > > window.parent.Wicket.Window.current > > > > > > > > If so, look at what moment they are nullified. The close method called > > on > > > > response: > > > > win.current.close() > > > > depends on these variables. > > > > > > > > > > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > > > > > >> > > > >> > > > >> Looking for hints to debug the situation I am in. Thanks. > > > >> > > > >> Using wickets 1.4.1 > > > >> > > > >> I have tried a simple scenario - opening a page in a modal window and > > > >> then using a link in the page to close the window. Works fine. > > > >> > > > >> Now I am opening a more complicated page with its own javascript - > > > >> performing a bunch of operations on that page using js while it is > > opened in > > > >> a modal window. At the end of the operations I hide all the divs and > > then > > > >> show a div that has a "close link" > > > >> > > > >> The link does not close the modal window - I see the request coming to > > the > > > >> server I call close(target) tried ModalWindow.close(target) too but > > nothing > > > >> happens. > > > >> > > > >> The window closes with the X close button on the top right. > > > >> > > > >> the wicket debug shows the operation / at least being able to fetch > > the > > > >> code to shut the window down succeeding . > > > >> > > > >> > > > >> > > http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 > > > >> > > > >> > > >> encoding="UTF-8"?> > > > >> > > > >> _ > > > >> Hotmail: Free, trusted and rich email service. > > > >> http://clk.atdmt.com/GBL/go/171222984/direct/01/ > > > >> > > > > > > > > > > > > _ > > Bing brings you health info from trusted sources. > > > > http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1 _ Hotmail: Powerful Free email with security by Microsoft. http://clk.atdmt.com/GBL/go/171222986/direct/01/
Re: Unable to close ModalWindow 1.4.1
- I get permission denied exception as reported by firebug. - head section with my javascript The firebug firefox plugging has an javascript console. Execute on him ( maybe you will not to get permission denied here): alert(Wicket.Window.current) alert(window.parent.Wicket.Window.current) at the end of the javascript operations you report: "At the end of the operations I hide all the divs and then show a div that has a "close link"" and let us to know what value then have. call the alerts to output the values, On Tue, Sep 15, 2009 at 9:13 PM, Ed _ wrote: > > Thanks for the suggestion. > > I have been using close(target) - unfortunately attached a run when I was > using both methods. Even with one ajax response appended it doesn't work. > > New to JS - can you tell me how to test the variables. If I add > > var status = window.parent.Wicket.Window; as part of my JS - I get > permission denied exception as reported by firebug. > > > My html file includes a head section with my javascript and the markup has > wicket elements viz where the close links are rendered. I have two such > links - both of which are rendered useless when used in this configuration - > although the main close button of the modalwindow continues to work. > > thanks > > > Date: Tue, 15 Sep 2009 18:00:47 -0300 > > Subject: Re: Unable to close ModalWindow 1.4.1 > > From: pedros...@gmail.com > > To: users@wicket.apache.org > > > > by close(target) or ModalWindow.close(target) > > --> use close(target), to maintain ModalWindow internal states updated. > > > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos > wrote: > > > > > On this ajax response, we can see that the close script was appended 2 > > > times. Make sure that it appended only once, by close(target) or > > > ModalWindow.close(target). > > > Before click the "close link", in a moment that was causing trouble, > see if > > > these variables are not null: > > > > > > Wicket.Window.current > > > window.parent.Wicket.Window.current > > > > > > If so, look at what moment they are nullified. The close method called > on > > > response: > > > win.current.close() > > > depends on these variables. > > > > > > > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > > > >> > > >> > > >> Looking for hints to debug the situation I am in. Thanks. > > >> > > >> Using wickets 1.4.1 > > >> > > >> I have tried a simple scenario - opening a page in a modal window and > > >> then using a link in the page to close the window. Works fine. > > >> > > >> Now I am opening a more complicated page with its own javascript - > > >> performing a bunch of operations on that page using js while it is > opened in > > >> a modal window. At the end of the operations I hide all the divs and > then > > >> show a div that has a "close link" > > >> > > >> The link does not close the modal window - I see the request coming to > the > > >> server I call close(target) tried ModalWindow.close(target) too but > nothing > > >> happens. > > >> > > >> The window closes with the X close button on the top right. > > >> > > >> the wicket debug shows the operation / at least being able to fetch > the > > >> code to shut the window down succeeding . > > >> > > >> > > >> > http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 > > >> > > >> > >> encoding="UTF-8"?> > > >> > > >> _ > > >> Hotmail: Free, trusted and rich email service. > > >> http://clk.atdmt.com/GBL/go/171222984/direct/01/ > > >> > > > > > > > > _ > Bing brings you health info from trusted sources. > > http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1
RE: Unable to close ModalWindow 1.4.1
Here is the wicket AJax Debug INFO: focus set on cancelUpdatea8INFO: Using XMLHttpRequest transportINFO: INFO: Initiating Ajax GET request on ?wicket:interface=modal-dialog-pagemap:26:cancelUpdate::IBehaviorListener:0:&random=0.5391539823210829INFO: Invoking pre-call handler(s)...INFO: Received ajax response (541 characters)INFO: INFO: Response parsed. Now invoking steps...INFO: Response processed successfully.INFO: Invoking post-call handler(s)...INFO: refocus last focused component not needed/allowedINFO: focus removed from cancelUpdatea8 > Date: Tue, 15 Sep 2009 18:00:47 -0300 > Subject: Re: Unable to close ModalWindow 1.4.1 > From: pedros...@gmail.com > To: users@wicket.apache.org > > by close(target) or ModalWindow.close(target) > --> use close(target), to maintain ModalWindow internal states updated. > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos wrote: > > > On this ajax response, we can see that the close script was appended 2 > > times. Make sure that it appended only once, by close(target) or > > ModalWindow.close(target). > > Before click the "close link", in a moment that was causing trouble, see if > > these variables are not null: > > > > Wicket.Window.current > > window.parent.Wicket.Window.current > > > > If so, look at what moment they are nullified. The close method called on > > response: > > win.current.close() > > depends on these variables. > > > > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > >> > >> > >> Looking for hints to debug the situation I am in. Thanks. > >> > >> Using wickets 1.4.1 > >> > >> I have tried a simple scenario - opening a page in a modal window and > >> then using a link in the page to close the window. Works fine. > >> > >> Now I am opening a more complicated page with its own javascript - > >> performing a bunch of operations on that page using js while it is opened > >> in > >> a modal window. At the end of the operations I hide all the divs and then > >> show a div that has a "close link" > >> > >> The link does not close the modal window - I see the request coming to the > >> server I call close(target) tried ModalWindow.close(target) too but nothing > >> happens. > >> > >> The window closes with the X close button on the top right. > >> > >> the wicket debug shows the operation / at least being able to fetch the > >> code to shut the window down succeeding . > >> > >> > >> http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 > >> > >> >> encoding="UTF-8"?> > >> > >> _ > >> Hotmail: Free, trusted and rich email service. > >> http://clk.atdmt.com/GBL/go/171222984/direct/01/ > >> > > > > _ Bing brings you health info from trusted sources. http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1
RE: Unable to close ModalWindow 1.4.1
Thanks for the suggestion. I have been using close(target) - unfortunately attached a run when I was using both methods. Even with one ajax response appended it doesn't work. New to JS - can you tell me how to test the variables. If I add var status = window.parent.Wicket.Window; as part of my JS - I get permission denied exception as reported by firebug. My html file includes a head section with my javascript and the markup has wicket elements viz where the close links are rendered. I have two such links - both of which are rendered useless when used in this configuration - although the main close button of the modalwindow continues to work. thanks > Date: Tue, 15 Sep 2009 18:00:47 -0300 > Subject: Re: Unable to close ModalWindow 1.4.1 > From: pedros...@gmail.com > To: users@wicket.apache.org > > by close(target) or ModalWindow.close(target) > --> use close(target), to maintain ModalWindow internal states updated. > > On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos wrote: > > > On this ajax response, we can see that the close script was appended 2 > > times. Make sure that it appended only once, by close(target) or > > ModalWindow.close(target). > > Before click the "close link", in a moment that was causing trouble, see if > > these variables are not null: > > > > Wicket.Window.current > > window.parent.Wicket.Window.current > > > > If so, look at what moment they are nullified. The close method called on > > response: > > win.current.close() > > depends on these variables. > > > > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > >> > >> > >> Looking for hints to debug the situation I am in. Thanks. > >> > >> Using wickets 1.4.1 > >> > >> I have tried a simple scenario - opening a page in a modal window and > >> then using a link in the page to close the window. Works fine. > >> > >> Now I am opening a more complicated page with its own javascript - > >> performing a bunch of operations on that page using js while it is opened > >> in > >> a modal window. At the end of the operations I hide all the divs and then > >> show a div that has a "close link" > >> > >> The link does not close the modal window - I see the request coming to the > >> server I call close(target) tried ModalWindow.close(target) too but nothing > >> happens. > >> > >> The window closes with the X close button on the top right. > >> > >> the wicket debug shows the operation / at least being able to fetch the > >> code to shut the window down succeeding . > >> > >> > >> http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 > >> > >> >> encoding="UTF-8"?> > >> > >> _ > >> Hotmail: Free, trusted and rich email service. > >> http://clk.atdmt.com/GBL/go/171222984/direct/01/ > >> > > > > _ Bing brings you health info from trusted sources. http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1
Re: Unable to close ModalWindow 1.4.1
by close(target) or ModalWindow.close(target) --> use close(target), to maintain ModalWindow internal states updated. On Tue, Sep 15, 2009 at 5:56 PM, Pedro Santos wrote: > On this ajax response, we can see that the close script was appended 2 > times. Make sure that it appended only once, by close(target) or > ModalWindow.close(target). > Before click the "close link", in a moment that was causing trouble, see if > these variables are not null: > > Wicket.Window.current > window.parent.Wicket.Window.current > > If so, look at what moment they are nullified. The close method called on > response: > win.current.close() > depends on these variables. > > > On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > >> >> >> Looking for hints to debug the situation I am in. Thanks. >> >> Using wickets 1.4.1 >> >> I have tried a simple scenario - opening a page in a modal window and >> then using a link in the page to close the window. Works fine. >> >> Now I am opening a more complicated page with its own javascript - >> performing a bunch of operations on that page using js while it is opened in >> a modal window. At the end of the operations I hide all the divs and then >> show a div that has a "close link" >> >> The link does not close the modal window - I see the request coming to the >> server I call close(target) tried ModalWindow.close(target) too but nothing >> happens. >> >> The window closes with the X close button on the top right. >> >> the wicket debug shows the operation / at least being able to fetch the >> code to shut the window down succeeding . >> >> >> http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 >> >> > encoding="UTF-8"?> >> >> _ >> Hotmail: Free, trusted and rich email service. >> http://clk.atdmt.com/GBL/go/171222984/direct/01/ >> > >
Re: Unable to close ModalWindow 1.4.1
On this ajax response, we can see that the close script was appended 2 times. Make sure that it appended only once, by close(target) or ModalWindow.close(target). Before click the "close link", in a moment that was causing trouble, see if these variables are not null: Wicket.Window.current window.parent.Wicket.Window.current If so, look at what moment they are nullified. The close method called on response: win.current.close() depends on these variables. On Tue, Sep 15, 2009 at 4:54 PM, Ed _ wrote: > > > Looking for hints to debug the situation I am in. Thanks. > > Using wickets 1.4.1 > > I have tried a simple scenario - opening a page in a modal window and then > using a link in the page to close the window. Works fine. > > Now I am opening a more complicated page with its own javascript - > performing a bunch of operations on that page using js while it is opened in > a modal window. At the end of the operations I hide all the divs and then > show a div that has a "close link" > > The link does not close the modal window - I see the request coming to the > server I call close(target) tried ModalWindow.close(target) too but nothing > happens. > > The window closes with the X close button on the top right. > > the wicket debug shows the operation / at least being able to fetch the > code to shut the window down succeeding . > > > http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 > > > > _ > Hotmail: Free, trusted and rich email service. > http://clk.atdmt.com/GBL/go/171222984/direct/01/ >
Unable to close ModalWindow 1.4.1
Looking for hints to debug the situation I am in. Thanks. Using wickets 1.4.1 I have tried a simple scenario - opening a page in a modal window and then using a link in the page to close the window. Works fine. Now I am opening a more complicated page with its own javascript - performing a bunch of operations on that page using js while it is opened in a modal window. At the end of the operations I hide all the divs and then show a div that has a "close link" The link does not close the modal window - I see the request coming to the server I call close(target) tried ModalWindow.close(target) too but nothing happens. The window closes with the X close button on the top right. the wicket debug shows the operation / at least being able to fetch the code to shut the window down succeeding . http://hostname/?wicket:interface=mymodalWindow:3:doneInstall::IBehaviorListener:0:&random=0.3818687947575885 _ Hotmail: Free, trusted and rich email service. http://clk.atdmt.com/GBL/go/171222984/direct/01/
Re: Unable to close modalwindow
On Fri, May 9, 2008 at 8:24 AM, tsuresh <[EMAIL PROTECTED]> wrote: > > Yes Mr Mean > I tried as , you suggested. When I created a single ModalWindow outside of > dataview it showed the error > "Unable to find component with id 'modalS'"So i didn't do it. Please show me the code and html when you tried this, it should work and would make the closing problem a lot simpler if not disappear. > > I deleted the > modalS.close(target); > > from the windowClosedCallBack. > > Other things are unchanged . > > This code does the tasks of editing but could not close the modalwindow in > firefox. But in IE 6.0 it even does not do the task of editing. > > I need your help. And please tell me the information you need. I am using > wicket 1.3.0 You could try wicket 1.3.3, there have been a few fixes to the modal window although not directly related to your closing problem. Also if Martijn was reading this he would probably suggest to use a Page instead of a Panel as they generally give less problems with forms and ajax and stuff. But for simple cases a Panel should also work (i am currently working on a modalwindow with a Panel too, yeah Martijn go sue me :P). So if you cannot get a singlemodalwindow to work please provide a quickstart and i'll have a look. Maurice - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Unable to close modalwindow
Yes Mr Mean I tried as , you suggested. When I created a single ModalWindow outside of dataview it showed the error "Unable to find component with id 'modalS'"So i didn't do it. I deleted the modalS.close(target); from the windowClosedCallBack. Other things are unchanged . This code does the tasks of editing but could not close the modalwindow in firefox. But in IE 6.0 it even does not do the task of editing. I need your help. And please tell me the information you need. I am using wicket 1.3.0 thanks suresh Mr Mean wrote: > > Did you try my suggestions? > What does the code look like now? > Can you reproduce this in a quickstart? > If you want our help you need to give us some more info. > > Maurice > > On Fri, May 2, 2008 at 7:50 AM, tsuresh <[EMAIL PROTECTED]> wrote: >> >> Hello All, >>I am still unable to close this modal window. Could someone please >> help >> me to close it or show my mistakes in the code in the first post. >> >> thanks >> tsuresh >> -- >> View this message in context: >> http://www.nabble.com/Unable-to-close-modalwindow-tp16981993p16996698.html >> >> >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > --------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Unable-to-close-modalwindow-tp16981993p17142038.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Unable to close modalwindow
Did you try my suggestions? What does the code look like now? Can you reproduce this in a quickstart? If you want our help you need to give us some more info. Maurice On Fri, May 2, 2008 at 7:50 AM, tsuresh <[EMAIL PROTECTED]> wrote: > > Hello All, >I am still unable to close this modal window. Could someone please help > me to close it or show my mistakes in the code in the first post. > > thanks > tsuresh > -- > View this message in context: > http://www.nabble.com/Unable-to-close-modalwindow-tp16981993p16996698.html > > > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Unable to close modalwindow
Hello All, I am still unable to close this modal window. Could someone please help me to close it or show my mistakes in the code in the first post. thanks tsuresh -- View this message in context: http://www.nabble.com/Unable-to-close-modalwindow-tp16981993p16996698.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Unable to close modalwindow
It looks like you are creating a new modalwindow for each item. Try creating 1 modalwindow outside the dataview and update the content (just as you are doing now) in the onclick of your edit link. Also you should not call modalwindow.close from inside your windowClosedCallBack, not sure what effect it will have but it is completely pointless as the window has already been closed. in this case by the code in the onsubmit. Maurice On Wed, Apr 30, 2008 at 3:02 PM, tsuresh <[EMAIL PROTECTED]> wrote: > > Hello All, > I am unable to close modalwindow which contains a panel with the form.My > code snippet in page is as > > follows: > . > > final DataView dataView = new DataView("rows", new > ListDataProvider(folderList)) { > > public void populateItem(final Item item) { > FolderWrapper fw = (FolderWrapper) > item.getModelObject(); > item.add(new CheckBox("checkbox", new PropertyModel(fw, > "selected"))); > item.add(new Label("subKeyword", > fw.getKeyword().getSubKeyword())); > item.add(new Label("description", > fw.getKeyword().getDescription())); > item.add(new Label("email", > fw.getKeyword().getEmail())); > > AjaxLink editLink = new AjaxLink("edit") { > > public void onClick(AjaxRequestTarget target) { > FolderWrapper selectedKeyword = > (FolderWrapper)getParent().getModelObject(); > modalS.setContent(new > FolderEditPanel(modalS.getContentId(), > selectedKeyword.getKeyword(), modalS)); > modalS.setTitle("Details:"); > modalS.show(target); > } > }; > > modalS = new ModalWindow("modalS"); > modalS.setInitialWidth(450); > modalS.setInitialHeight(200); > modalS.setWindowClosedCallback(new > ModalWindow.WindowClosedCallback() { > > public void onClose(AjaxRequestTarget target) { > modalS.close(target); > } > }); > editLink.add(modalS); > item.add(editLink); > > . > > > And the Panel which contains edit form : > > public FolderEditPanel(String id, Keyword keyword, final ModalWindow > window) { > super(id); > selectedKeyword = keyword; > Form folderEditForm = new FolderEditForm("form"); > folderEditForm.setOutputMarkupId(true); > add(folderEditForm); > folderEditForm.add(new AjaxButton("ok") { > > @Override > protected void onSubmit(AjaxRequestTarget target, Form form) { > try { > selectedKeyword.edit(); > } catch (SQLException e) { > String err = e.getMessage(); > } > window.close(target); > } > }); > } > > But similar codes works fine when I don't use wrapper(i.e FolderWrapper to > add checkbox to select > > items). > > Thanks, > tsuresh > > -- > View this message in context: > http://www.nabble.com/Unable-to-close-modalwindow-tp16981993p16981993.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Unable to close modalwindow
Hello All, I am unable to close modalwindow which contains a panel with the form.My code snippet in page is as follows: . final DataView dataView = new DataView("rows", new ListDataProvider(folderList)) { public void populateItem(final Item item) { FolderWrapper fw = (FolderWrapper) item.getModelObject(); item.add(new CheckBox("checkbox", new PropertyModel(fw, "selected"))); item.add(new Label("subKeyword", fw.getKeyword().getSubKeyword())); item.add(new Label("description", fw.getKeyword().getDescription())); item.add(new Label("email", fw.getKeyword().getEmail())); AjaxLink editLink = new AjaxLink("edit") { public void onClick(AjaxRequestTarget target) { FolderWrapper selectedKeyword = (FolderWrapper)getParent().getModelObject(); modalS.setContent(new FolderEditPanel(modalS.getContentId(), selectedKeyword.getKeyword(), modalS)); modalS.setTitle("Details:"); modalS.show(target); } }; modalS = new ModalWindow("modalS"); modalS.setInitialWidth(450); modalS.setInitialHeight(200); modalS.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() { public void onClose(AjaxRequestTarget target) { modalS.close(target); } }); editLink.add(modalS); item.add(editLink); . And the Panel which contains edit form : public FolderEditPanel(String id, Keyword keyword, final ModalWindow window) { super(id); selectedKeyword = keyword; Form folderEditForm = new FolderEditForm("form"); folderEditForm.setOutputMarkupId(true); add(folderEditForm); folderEditForm.add(new AjaxButton("ok") { @Override protected void onSubmit(AjaxRequestTarget target, Form form) { try { selectedKeyword.edit(); } catch (SQLException e) { String err = e.getMessage(); } window.close(target); } }); } But similar codes works fine when I don't use wrapper(i.e FolderWrapper to add checkbox to select items). Thanks, tsuresh -- View this message in context: http://www.nabble.com/Unable-to-close-modalwindow-tp16981993p16981993.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]