Re: http/https in wicket 1.5
You can mark specific pages as HTTPS specific using @requiresHttps. Then just set the ports in your application class. setRootRequestMapper(new HttpsMapper(getRootRequestMapper(), new HttpsConfig(80, 443))); On 1 March 2012 14:10, Douglas Ferguson wrote: > In 1.4 I had ao code up some interesting work arounds to get my app to > redirect between http and https based on which page you are requesting. > > I remember at the time Igor told me that it would be much easer in 1.5. > Can anybody point me in the redirection? > > I'm considering 2 schemes. > > 1) Running the entire app over ssl (then I just need to detect http and > redirect to https) > 2) Keep it as is, Only have the login, signup and payment screens be https > and then redirect to http. > > Regardless I'll need to detect http/https and then redirect if necessary. > Would this still be done in the AuthorizationStrategy? > > I've noticed that RequestCycle has changed, and many methods I used are > gone. > I.E. I used to use requestCycle.getPageParameters() to get the parameters > do that I when I redirected to login I would retain the params, > so after logging in the user could be sent to their original page. > > Douglas > > > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: A/B testing with wicket
You can use style and variation. Setting default style works automatically to load differing HTML files for the same components. https://cwiki.apache.org/WICKET/localization-and-skinning-of-applications.html On 20 April 2012 09:08, Decebal Suiu wrote: > Maybe Google Website Optimizer/ Google Analytics and not Google AddWords. > My > idea is to use Component.getVariation() as start point. > > Best reagrds, > Decebal > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/A-B-testing-with-wicket-tp4571946p4573185.html > Sent from the Users forum mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
JSessionID breaking my dropdown
I have the following Dropdown added to my code. DropDownChoice listSites = new DropDownChoice("localeSelect", new PropertyModel(this, "selected"), currentProductLocales) { /** * */ private static final long serialVersionUID = 1L; protected boolean wantOnSelectionChangedNotifications() { return true; } /** * Called when a option is selected of a dropdown list that wants to * be notified of this event. * * @param newSelection *The newly selected object of the backing model */ protected void onSelectionChanged(final String newSelection) { List ListofLocalesCurrency = new ArrayList(); ListofLocalesCurrency = productController.getCurrencyCountry(MyAuthenticatedWebSession.get().getProduct()); List currentProductLocales = new ArrayList(); // get the list of currencies/countries/languages for this // product, and set them as default for (LocaleCurrency localeCurrency : ListofLocalesCurrency) { if (selected.equals(localeCurrency.getDisplayName())) { MyAuthenticatedWebSession.get().setLocalCurrency(localeCurrency); localeCurrency.setDefaultLocale(); } } ; } };
Re: JSessionID breaking my dropdown
sorry sent accidentally. On 1 May 2012 16:16, Fergal Keating wrote: > > I have the following Dropdown added to my code. > > DropDownChoice listSites = new > DropDownChoice("localeSelect", new PropertyModel(this, > "selected"), currentProductLocales) > { > /** > * > */ > private static final long serialVersionUID = 1L; > > protected boolean wantOnSelectionChangedNotifications() > { > return true; > } > > /** > * Called when a option is selected of a dropdown list that wants to > * be notified of this event. > * > * @param newSelection > *The newly selected object of the backing model > */ > protected void onSelectionChanged(final String newSelection) > { > List ListofLocalesCurrency = new > ArrayList(); > ListofLocalesCurrency = > productController.getCurrencyCountry(MyAuthenticatedWebSession.get().getProduct()); > > List currentProductLocales = new ArrayList(); > > // get the list of currencies/countries/languages for this > // product, and set them as default > for (LocaleCurrency localeCurrency : ListofLocalesCurrency) > { > > if (selected.equals(localeCurrency.getDisplayName())) > { > MyAuthenticatedWebSession.get().setLocalCurrency(localeCurrency); > localeCurrency.setDefaultLocale(); > } > > } > ; > } > }; > > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
JsessionID breaking my DropDownChoice#onSelectionChanged
Apologies if this has been covered before, but i havn't found anything with this specific issue. I have a Dropdown added to my code, but when a user first accesses the site, the URL gets appended with JsessionID. This seems to break the link, and the #onSelectionChanged never gets called. Is there any way to prevent this? When i select initially it calls http://localhost:8080/;jsessionid=1ftbjrge1ri51hpybjnwcuhe5?0-1.IFormSubmitListener-headerPanel-content-localePanel-form and the page just reloads. I want my code to work with JSessionID so I can support lack of cookies up to a point. has there been any workaround for this? DROPDOWN CODE DropDownChoice listSites = new DropDownChoice("localeSelect", new PropertyModel(this, "selected"), currentProductLocales) { private static final long serialVersionUID = 1L; protected boolean wantOnSelectionChangedNotifications() {return true;} protected void onSelectionChanged(final String newSelection) { List ListofLocalesCurrency = new ArrayList(); ListofLocalesCurrency = productController.getCurrencyCountry(MyAuthenticatedWebSession.get().getProduct()); List currentProductLocales = new ArrayList(); for (LocaleCurrency localeCurrency : ListofLocalesCurrency) { if (selected.equals(localeCurrency.getDisplayName())) { MyAuthenticatedWebSession.get().setLocalCurrency(localeCurrency); localeCurrency.setDefaultLocale(); } } ; } };
Re: JsessionID breaking my DropDownChoice#onSelectionChanged
Hi, I havn't been able to recreate with a quickstart. Not sure why its appending the sessionID. #getContextRelativeUrl() is getting called correctly. So it must be elsewhere in application. I'll keep looking. Fergal. On 1 May 2012 18:21, Sven Meier wrote: > Hi, > > I just verified with blocked cookies on a quickstart and it works fine > here. > > ServletWebRequest#**getContextRelativeUrl() strips the session id from > the uri, so running without cookies should be no problem. > > Perhaps something else is going wrong, you should build a quickstart and > attach it to a JIRA issue. > > Sven > > > On 05/01/2012 06:02 PM, Fergal Keating wrote: > >> Apologies if this has been covered before, but i havn't found anything >> with >> this specific issue. >> >> I have a Dropdown added to my code, but when a user first accesses the >> site, the URL gets appended with JsessionID. This seems to break the link, >> and the #onSelectionChanged never gets called. Is there any way to prevent >> this? >> >> When i select initially it calls >> http://localhost:8080/;**jsessionid=**1ftbjrge1ri51hpybjnwcuhe5?0-1.** >> IFormSubmitListener-**headerPanel-content-**localePanel-form<http://localhost:8080/;jsessionid=1ftbjrge1ri51hpybjnwcuhe5?0-1.IFormSubmitListener-headerPanel-content-localePanel-form> >> >> and the page just reloads. >> >> I want my code to work with JSessionID so I can support lack of cookies up >> to a point. has there been any workaround for this? >> >> >> DROPDOWN CODE >> DropDownChoice listSites = new >> DropDownChoice("**localeSelect", new PropertyModel(this, >> "selected"), currentProductLocales) >> { >> private static final long serialVersionUID = 1L; >> >> protected boolean wantOnSelectionChangedNotifica**tions() >> {return true;} >> >> protected void onSelectionChanged(final String newSelection) >> { >> List ListofLocalesCurrency = new >> ArrayList(); >> ListofLocalesCurrency = >> productController.**getCurrencyCountry(**MyAuthenticatedWebSession.get(** >> ).getProduct()); >> >> List currentProductLocales = new ArrayList(); >> >> for (LocaleCurrency localeCurrency : ListofLocalesCurrency) >> { >> >> if (selected.equals(**localeCurrency.getDisplayName(**))) >> { >> MyAuthenticatedWebSession.get(**).setLocalCurrency(**localeCurrency); >> localeCurrency.**setDefaultLocale(); >> } >> >> } >> ; >> } >> }; >> >> > > --**--**- > To unsubscribe, e-mail: > users-unsubscribe@wicket.**apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: Wicket Examples
I got a PermGen space error on that URL. javax.servlet.ServletException: Filter execution threw an exception *root cause* java.lang.OutOfMemoryError: PermGen space On 8 May 2012 08:31, Martin Grigorov wrote: > > http://www.wicket-library.com/wicket-examples/repeater/wicket/bookmarkable/org.apache.wicket.examples.repeater.FormPage > works OK for me > > On Tue, May 8, 2012 at 12:43 AM, Corbin, James > wrote: > > The wicket examples (www.wicket-library.com/wicket-examples/) seems to > be having issues. > > > > I select the Contacts Editor option under the repeaters section and I > get a permgen error. > > > > Is this site working properly? I assume the URL above is appropriate? > > > > J.D. > > > > -- > Martin Grigorov > jWeekend > Training, Consulting, Development > http://jWeekend.com > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: re-direct after pop-up notification
Hi, Seems to me like you just added JS to the target, but then redirected so instead of the current page being updated with the JS, it just loads the new page. Im not sure what your trying to get at, however maybe an alternate solution is when a form is updated you could make visible an AlertPanel which gets the user to click an OK button. then override the Onclick for the button in the AltertPanel to redirect to new page. (or just have the OK button be a link to a new page directly) Fergal. On 19 July 2012 12:46, oliver.stef wrote: > Hi all, > > I wan't to display a pop-up message and after that (after the user pressed > on he "OK" button inside the pop-up notification) i wan't to re-direct him > to a new page. > > i tried to do the following: (from NewPage1) > try { > runMe( form ); > > target.appendJavascript("alert('submitted successfully')"); > //after the > user press 'OK' --> display NewPage2 > > setResponsePage(NewPage2.class); //re-direct to NewPage2 > } > > but he won't show me the "submitted successfully" message, he re-direct me > straight to NewPage2. > > any ideas?? > > Thanks! > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/re-direct-after-pop-up-notification-tp4650621.html > Sent from the Users forum mailing list archive at Nabble.com. > > --------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: how to get dropdownlist selected value
attrvalueChoice.getModelObject(); On 26 July 2012 10:15, lxw_first wrote: > http://apache-wicket.1842946.n4.nabble.com/file/n4650788/aaa.bmp > > html: > > > > > > code > final ListView trView=new ListView("tritems", new PropertyModel(this, > "attrBizRoles")) { > private IBizRole attrvalueBizRole=new BizRole(); > > @Override > protected void populateItem(ListItem item) { > attrBizRole = (IBizRole) item.getModelObject(); > item.add(new Label("lblattr", attrBizRole.getName())); > // this list can get from attr > attrvalueBizRoles = (List) > attrBizRole.getChildBizRole(); > if (attrvalueBizRoles.size()>0) { > attrvalueBizRole=attrvalueBizRoles.get(0); > } > DropDownChoice attrvalueChoice = new > DropDownChoice("attrvalue",new > PropertyModel(this, "attrvalueBizRole"), attrvalueBizRoles,new > IChoiceRenderer() { > > @Override > public Object getDisplayValue(Object object) { > attrvalueBizRole = (IBizRole) object; > return attrvalueBizRole.getName(); > } > > @Override > public String getIdValue(Object object, int index) > { > attrvalueBizRole = (IBizRole) object; > return > String.valueOf(attrvalueBizRole.getId()); > } > }); > item.add(attrvalueChoice); > } > }; > > i want to get the dropdownlist selected value.how to get value? > Can anyone tell me how to achieve this. > Thanks > > > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/how-to-get-dropdownlist-selected-value-tp4650788.html > Sent from the Users forum mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: Best practices for passing configurations, such as Facebook app_id, to JavaScript
*HTML* * * /* script will be rendered here */ *JAVA* String FacbookJS = " var facebookID = \"" + this.getfacebookID(CurrentDomain) + "\"); "; Label FacebookLabel = new Label("Facebookjs", FacbookJS ); addOrReplace( FacebookLabel.setEscapeModelStrings(false)); On 27 August 2012 15:33, Alec Swan wrote: > Hello, > > We deploy our web app on different domains which means that JavaScript > Facebook integration needs to use different app_id values. I am > planning to store these values in a configuration file and wonder how > to expose them to JavaScript. I would also like to write a unit test > that verifies that settings were passed correctly. > > I could use a HeaderContributor to inject raw JavaScript, but this > doesn't seem to be very unit-testable. I could create a which > attributes/elements contain the settings, which seems to be more > unit-testable. > > Thoughts? > > Thanks, > > Alec > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: Using and creating URLs to Bookmarkable Pages without Wicket Application
Im not clear if this is what your looking for, but it seems you just need to set your application to be able to accept the URL format http://wicket.website.com/ConfirmationPage/?user=foo&token=1234<http://wicket.website.com/ConfirmationPage.html?user=foo&token=1234> and then you can generate it maually in your emails. In your MyApplication#init() you can mount a page to mountPage("/confirmationpage/", ConfirmationPage.class); Then create your ConfirmationPage to accept parameters..something like public class ConfirmationPage{ public ConfirmationPage (final PageParameters parameters) { StringValue token= parameters.get("token"); StringValue user= parameters.get("user"); } } On 14 September 2012 12:46, Dirk Forchel wrote: > What is the prefered way in Wicket 1.5 to create page links to access a > wicket page, e.g. using this link in an email. In my case, we need a link > to > a "subscription page" in a Wicket application. When a new user subscribes a > confirmation email containing the link to this wicket page has to be sent. > I know the usual way how to generate URLs with a wicket application (see > https://cwiki.apache.org/WICKET/getting-a-url-for-display.html > https://cwiki.apache.org/WICKET/getting-a-url-for-display.html ). But I > want > to create links like this > "http://wicket.website.com/ConfirmationPage.html?user=foo&token=1234"; > outside a Wicket application and from another WebServlet. > > My intentation was to use an interface like IEmailUrlProvider with methods > returning the required URL strings. > > > > And let Wicket do the generation part like: > > > Is this the prefered way to do this with Wicket? Or do I miss something? > Any > other hints? > > > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/Using-and-creating-URLs-to-Bookmarkable-Pages-without-Wicket-Application-tp4652002.html > Sent from the Users forum mailing list archive at Nabble.com. > > --------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: bookmarkable page being processed twice, second time, extra parameters passed
The only similar issues i have come across are with plugins to my browser (firebug etc) causing second requests without any parameters. But this may be something similar. On 17 September 2012 11:18, lucast wrote: > Dear Forum, > I have a bookmarkable page which can take two parameters: > uniqueName=[uniqueName] and unique_id_key=[] > > For some reason, the page is being instantiated twice. > The first time, the right parameters are being passed. > > The second time, a lot of parameters are being passed and one of the > parameters has the wrong value: > 0=[panel], 1=[style.css], uniqueName=[uniqueName], unique_id_key=[style] > > Has anyone experienced this before? how can one stop the second request > coming through? > > Thanks in advance, > Lucas > > > > -- > View this message in context: > http://apache-wicket.1842946.n4.nabble.com/bookmarkable-page-being-processed-twice-second-time-extra-parameters-passed-tp4652031.html > Sent from the Users forum mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Wicket 6.5.0 upgrade, Extensions Wizard, ApplyState() not called
Hello, I'm trying to update a wicket 1.5.5 application to 6.5.0. I have overcome some issues with Header items, and setting Attributes to AllowDefault(true) for ajax. I have one remaining issue that i cant seem to figure out. I have a wizard that allows users to create a booking. (See currently working version on following Link + "Click Book") http://www.directski.com/ski/france/la_plagne/residence_prestige_sun_valley When you click Next it calls the applyState() method. However on version 6.5.0, if you update the Group Size or departure, Clicking Next just reloads the page and the applyState() method is not called. The Group size and departure dropdowns merely use AjaxFormComponentUpdatingBehavior to update the object and sends a ComponentEvent message to the relevant panels to update themselves. Any ideas why applyState() might not be being called?
Re: Wicket 6.5.0 upgrade, Extensions Wizard, ApplyState() not called
Hi, If i put a breakpoint in renderCount (it gets called a lot) But the "resolvePageInstance" only gets called once per request, It seems to have the same renderCount Value that is on the current page. E.G. The page is displaying "booking?14-1" for all event listeners. If i change the GroupSize via the Dropdown then the PageProvider#getPageInstance() is being called with e.g. pageId=14 renderCount = 1. The Ajax response contains event Listeners for all the passenger names textboxes, all the URLs reference "booking?14-1.IBehaviorListener" as part of the URL, and when i type in a passenger name it looks like they are correctly called, but once i click Next the Names are lost. The Next Button reference a form with the following URL "./booking?14-1.IFormSubmitListener-wizard-form" Yet If i Click NEXT then the page refreshes again and all the Links rerender with "booking?14-3" This is consistent with wicket 1.5.5 on the Live site in the same browser, if i click Next without any passenger names it resets the Booking page, and moves from e.g 14-1 to 14-3.. I'm not 100% sure where i need to go from here. On 25 February 2013 13:50, Martin Grigorov wrote: > Hi, > > Such behavior can be experienced when the page is re-rendered in the > meantime, for example in a new tab/window. > See Page#renderCount javadoc for explanation. > To verify that this is or is not the case you can put a breakpoint in > PageProvider#getPageInstance() method. > > > On Mon, Feb 25, 2013 at 3:39 PM, Fergal Keating < > fergal.keat...@directski.com> wrote: > > > Hello, > > > > I'm trying to update a wicket 1.5.5 application to 6.5.0. I have overcome > > some issues with Header items, and setting Attributes to > > AllowDefault(true) for ajax. I have one remaining issue that i cant seem > to > > figure out. > > > > I have a wizard that allows users to create a booking. > > > > (See currently working version on following Link + "Click Book") > > > http://www.directski.com/ski/france/la_plagne/residence_prestige_sun_valley > > > > When you click Next it calls the applyState() method. However on version > > 6.5.0, if you update the Group Size or departure, Clicking Next just > > reloads the page and the applyState() method is not called. > > > > The Group size and departure dropdowns merely use > > AjaxFormComponentUpdatingBehavior to update the object and sends a > > ComponentEvent message to the relevant panels to update themselves. > > > > Any ideas why applyState() might not be being called? > > > > > > -- > Martin Grigorov > jWeekend > Training, Consulting, Development > http://jWeekend.com <http://jweekend.com/> > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: Wicket 6.5.0 upgrade, Extensions Wizard, ApplyState() not called
Hi, I seem to have solved the issue. I have made a number of changes to clarify and clean up code. However, as part of the Ajax requests for changing the GroupSize or Departure the component#Error method was called, but the feedback panel was not refreshed to display an error. Removing any messages being added to Component#Error seems to have solved the issue. Fergal. On 26 February 2013 12:25, Martin Grigorov wrote: > Hi, > > > On Tue, Feb 26, 2013 at 2:10 PM, Fergal Keating < > fergal.keat...@directski.com> wrote: > > > Hi, > > > > If i put a breakpoint in renderCount (it gets called a lot) But the > > "resolvePageInstance" only gets called once per request, It seems to > have > > the same renderCount Value that is on the current page. > > E.G. The page is displaying "booking?14-1" for all event listeners. > > > > > > If i change the GroupSize via the Dropdown then the > > PageProvider#getPageInstance() is being called with e.g. > > pageId=14 renderCount = 1. > > The Ajax response contains event Listeners for all the passenger names > > textboxes, all the URLs reference "booking?14-1.IBehaviorListener" as > part > > of the URL, and when i type in a passenger name it looks like they are > > correctly called, but once i click Next the Names are lost. > > > > The Next Button reference a form with the following URL > > "./booking?14-1.IFormSubmitListener-wizard-form" Yet If i Click NEXT then > > the page refreshes again and all the Links rerender with "booking?14-3" > > > > This is consistent with wicket 1.5.5 on the Live site in the same > browser, > > if i click Next without any passenger names it resets the Booking page, > and > > moves from e.g 14-1 to 14-3.. > > > > I'm not 100% sure where i need to go from here. > > > > I have no idea too. > If you are able to reproduce the problem in a mini application then attach > it to Jira and we will debug it. > > > > > > On 25 February 2013 13:50, Martin Grigorov wrote: > > > > > Hi, > > > > > > Such behavior can be experienced when the page is re-rendered in the > > > meantime, for example in a new tab/window. > > > See Page#renderCount javadoc for explanation. > > > To verify that this is or is not the case you can put a breakpoint in > > > PageProvider#getPageInstance() method. > > > > > > > > > On Mon, Feb 25, 2013 at 3:39 PM, Fergal Keating < > > > fergal.keat...@directski.com> wrote: > > > > > > > Hello, > > > > > > > > I'm trying to update a wicket 1.5.5 application to 6.5.0. I have > > overcome > > > > some issues with Header items, and setting Attributes to > > > > AllowDefault(true) for ajax. I have one remaining issue that i cant > > seem > > > to > > > > figure out. > > > > > > > > I have a wizard that allows users to create a booking. > > > > > > > > (See currently working version on following Link + "Click Book") > > > > > > > > > > http://www.directski.com/ski/france/la_plagne/residence_prestige_sun_valley > > > > > > > > When you click Next it calls the applyState() method. However on > > version > > > > 6.5.0, if you update the Group Size or departure, Clicking Next just > > > > reloads the page and the applyState() method is not called. > > > > > > > > The Group size and departure dropdowns merely use > > > > AjaxFormComponentUpdatingBehavior to update the object and sends a > > > > ComponentEvent message to the relevant panels to update themselves. > > > > > > > > Any ideas why applyState() might not be being called? > > > > > > > > > > > > > > > > -- > > > Martin Grigorov > > > jWeekend > > > Training, Consulting, Development > > > http://jWeekend.com <http://jweekend.com/> > > > > > > > > > > > -- > > Fergal Keating > > IT Senior Engineer > > --- > > e. fergal.keat...@directski.com > > p. NA > > w. www.directski.com > > > > > > -- > Martin Grigorov > jWeekend > Training, Consulting, Development > http://jWeekend.com <http://jweekend.com/> > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
FeedbackPanel Empty on Wizard in 6.5
Hi, I'm using a wizard page on which there is some feedback panels. On the last step, (since i upgraded to version 6.5 wicket) the feedback messages are not displaying. (they are working fine on other steps). I can correctly see each component in the form adding its own error message.The FinishButton#On Error is being called because there are errors detectcted, but they seem to be cleared by the time i have to display the feedback panel. I have even called error() from the overwritten FinishButton#On Error method and it seems to disappear. I have placed Debug on orw.feedback class which shows that my feedback messages are being added. but when the feedback Collector Class gets called to display the feedback messages they somehow seem to have disappeared. The feedback panel is set to visible, and its onBeforeRender is being called, but messages arent displayed. I've tried to see where the messages are being cleared, but it just seem that the FeedbackMessages#clear methods only being called on Detach. can someone advise ? -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: FeedbackPanel Empty on Wizard in 6.5
The MywizardPage is being used as the Root component and its set in the FeedbackCollector constructor. So it should be a parent of all components under it. Adding session.error to my FinishButton#OnError get the feedback panel displayed correctly with that one message, however i'm relying on component#setRequired for some of my error messages. so i need to get to the bottom of the issue. I added a check in the feedbackPanel to findParent(MywizardPage.class) and its returning correctly... On 25 March 2013 09:45, Martin Grigorov wrote: > Hi, > > Check which component is used as root in FeedbackCollector. Is it the page > or some other component which is not parent of the component on which you > call .error() method ? > As a workaround you can use session.error() instead but I think it will be > better if you understand why the component-scoped feedback message is not > used. > > > On Mon, Mar 25, 2013 at 11:17 AM, Fergal Keating < > fergal.keat...@directski.com> wrote: > > > Hi, > > > > I'm using a wizard page on which there is some feedback panels. On the > last > > step, (since i upgraded to version 6.5 wicket) the feedback messages are > > not displaying. (they are working fine on other steps). > > > > I can correctly see each component in the form adding its own error > > message.The FinishButton#On Error is being called because there are > errors > > detectcted, but they seem to be cleared by the time i have to display the > > feedback panel. I have even called error() from the overwritten > > FinishButton#On Error method and it seems to disappear. > > > > I have placed Debug on orw.feedback class which shows that my feedback > > messages are being added. but when the feedback Collector Class gets > called > > to display the feedback messages they somehow seem to have disappeared. > > > > The feedback panel is set to visible, and its onBeforeRender is being > > called, but messages arent displayed. I've tried to see where the > messages > > are being cleared, but it just seem that the FeedbackMessages#clear > methods > > only being called on Detach. > > > > can someone advise ? > > > > -- > > Fergal Keating > > IT Senior Engineer > > ------- > > e. fergal.keat...@directski.com > > p. NA > > w. www.directski.com > > > > > > -- > Martin Grigorov > jWeekend > Training, Consulting, Development > http://jWeekend.com <http://jweekend.com/> > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
Re: FeedbackPanel Empty on Wizard in 6.5
FYI, I couldn't resolve the issue. I had a couple of places with ListView and i made sure setReuseItems was (true) but that didn't resolve the issue. I tried removing various panels to track down the issue, but still nothing. However when i removed the .setRequired on some textboxes the form then processed and i was already throwing exceptions for invalid data, then catching exceptions and calling Error(exception.getmessage) <<-- Note calling error() at this point worked without referring to the sesssion as long as the form/submit was called. So i just updated the exceptions to check for null values in the model and set the error feedback that way. Fergal. On 25 March 2013 13:13, Martin Grigorov wrote: > Hi, > > Do you use ListView somewhere in the hierarchy by chance ? > I remember a similar issue - the component with the feedback message was in > a ListView with .setReuseItems(false). Changing it to .setReuseItems(true) > fixed the problem. > > > On Mon, Mar 25, 2013 at 3:06 PM, Fergal Keating < > fergal.keat...@directski.com> wrote: > > > The MywizardPage is being used as the Root component and its set in the > > FeedbackCollector constructor. So it should be a parent of all components > > under it. > > Adding session.error to my FinishButton#OnError get the feedback panel > > displayed correctly with that one message, however i'm relying on > > component#setRequired for some of my error messages. so i need to get to > > the bottom of the issue. > > > > I added a check in the feedbackPanel to findParent(MywizardPage.class) > and > > its returning correctly... > > > > > > > > > > On 25 March 2013 09:45, Martin Grigorov wrote: > > > > > Hi, > > > > > > Check which component is used as root in FeedbackCollector. Is it the > > page > > > or some other component which is not parent of the component on which > you > > > call .error() method ? > > > As a workaround you can use session.error() instead but I think it will > > be > > > better if you understand why the component-scoped feedback message is > not > > > used. > > > > > > > > > On Mon, Mar 25, 2013 at 11:17 AM, Fergal Keating < > > > fergal.keat...@directski.com> wrote: > > > > > > > Hi, > > > > > > > > I'm using a wizard page on which there is some feedback panels. On > the > > > last > > > > step, (since i upgraded to version 6.5 wicket) the feedback messages > > are > > > > not displaying. (they are working fine on other steps). > > > > > > > > I can correctly see each component in the form adding its own error > > > > message.The FinishButton#On Error is being called because there are > > > errors > > > > detectcted, but they seem to be cleared by the time i have to display > > the > > > > feedback panel. I have even called error() from the overwritten > > > > FinishButton#On Error method and it seems to disappear. > > > > > > > > I have placed Debug on orw.feedback class which shows that my > feedback > > > > messages are being added. but when the feedback Collector Class gets > > > called > > > > to display the feedback messages they somehow seem to have > disappeared. > > > > > > > > The feedback panel is set to visible, and its onBeforeRender is being > > > > called, but messages arent displayed. I've tried to see where the > > > messages > > > > are being cleared, but it just seem that the FeedbackMessages#clear > > > methods > > > > only being called on Detach. > > > > > > > > can someone advise ? > > > > > > > > -- > > > > Fergal Keating > > > > IT Senior Engineer > > > > --- > > > > e. fergal.keat...@directski.com > > > > p. NA > > > > w. www.directski.com > > > > > > > > > > > > > > > > -- > > > Martin Grigorov > > > jWeekend > > > Training, Consulting, Development > > > http://jWeekend.com <http://jweekend.com/> > > > > > > > > > > > -- > > Fergal Keating > > IT Senior Engineer > > --- > > e. fergal.keat...@directski.com > > p. NA > > w. www.directski.com > > > > > > -- > Martin Grigorov > jWeekend > Training, Consulting, Development > http://jWeekend.com <http://jweekend.com/> > -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
ERROR Error detaching RequestHandler in StalePageException
Hi, Every few minutes on our site, we get the following error. 08/12/2013 07:13:53 [?] ERROR ? Error detaching RequestHandler org.apache.wicket.core.request.mapper.StalePageException We're running wicket 6.5.0 (as we were on previous release without the issue). The errors seem to be correspond to bots accessing the site (e.g googlebot) trying to access links such as MOUNTED_URL/?0-1.IBehaviorListener.0-headerPanel-content-my Panel-form-mySelect MOUNTED_URL/?0-1.ILinkListener-panel-options-tabs-tabs~container-tabs-1-link I cannot seem to reproduce the issue locally, We don't have sessions for bots as we Override Application#newWebResponse as follows. protected WebResponse newWebResponse(final WebRequest webRequest, final HttpServletResponse httpServletResponse) { return new ServletWebResponse((ServletWebRequest) webRequest, httpServletResponse) { @Override public String encodeURL(CharSequence url) { final String agent = webRequest.getHeader("User-Agent"); logger.debug("User Agent:" + agent); if (isAgent(agent)) { MyAuthenticatedWebSession.get().invalidateNow(); return url.toString(); } return super.encodeURL(url).toString(); } }; } What could be causing the ERRORs? -- Fergal Keating IT Senior Engineer --- e. fergal.keat...@directski.com p. NA w. www.directski.com
wicket facebook,6.15 Circular dependency detected
Hi, I was attempting to upgrade to Wicket 6.15.0 from 6.5.0 in order to use As described in http://wicketinaction.com/2014/03/header-contributions-positioning/ This should nicely solve an issue I'm currently having in the HTML rather than the Java where i am using WRO4J to minimise and join javascript and CSS . I am also using wicket-facebook 6.15.0. I have run into a problem when i run my application. I get an error after facebooksdk.java line 99 The following error is thrown. org.apache.wicket.resource.CircularDependencyException: Circular dependency detected in the dependency chain [JavaScriptReferenceHeaderItem(scope: org.apache.wicket.Application; name: ; locale: null; style: null; variation: null, null)]. JavaScriptReferenceHeaderItem(scope: org.apache.wicket.Application; name: ; locale: null; style: null; variation: null, null) is already in the chain. It seems that for some reason a null reference is being added to the header. I do not get this error in 6.5.0. Is there some obvious change i am missing between the versions that can point me in the right direction? -- Fergal Keating
Re: wicket facebook,6.15 Circular dependency detected
Hi, I have discovered that the issue relates to how we are overriding the default Wicket javascript. We are adding the following to Application#init() addResourceReplacement((JavaScriptResourceReference) DirectSkiApplication.get().getJavaScriptLibrarySettings().getJQueryReference(), new UrlResourceReference(Url.parse(""))); addResourceReplacement((JavaScriptResourceReference) DirectSkiApplication.get().getJavaScriptLibrarySettings().getWicketEventReference(), new UrlResourceReference(Url.parse(""))); addResourceReplacement((JavaScriptResourceReference) DirectSkiApplication.get().getJavaScriptLibrarySettings().getWicketAjaxReference(), new UrlResourceReference(Url.parse(""))); addResourceReplacement((JavaScriptResourceReference) DirectSkiApplication.get().getJavaScriptLibrarySettings().getWicketAjaxDebugReference(),new UrlResourceReference(Url.parse(""))) We are then adding the correct resources as a bundle through wro4j.xml. (it was probably overkill but trying to load as a single bundled cached request. This worked in wicket 6.5.0 without throwing an error. What is the simplest way i can achieve the same functionality ? On 6 May 2014 20:29, Martin Grigorov wrote: > Hi, > > If you are able to reproduce this in a quickstart (mini) app then please > attach it to a ticket at https://issues.apache.org/jira/browse/WICKET > Thanks! > > Martin Grigorov > Wicket Training and Consulting > > > On Tue, May 6, 2014 at 5:43 PM, Fergal Keating < > fergal.keat...@directski.com > > wrote: > > > Hi, > > > > I was attempting to upgrade to Wicket 6.15.0 from 6.5.0 in order to use > > > > > > > > As described in > > http://wicketinaction.com/2014/03/header-contributions-positioning/ > > > > This should nicely solve an issue I'm currently having in the HTML rather > > than the Java where i am using WRO4J to minimise and join javascript and > > CSS . I am also using wicket-facebook 6.15.0. > > > > I have run into a problem when i run my application. I get an error after > > facebooksdk.java line 99 The following error is thrown. > > > > org.apache.wicket.resource.CircularDependencyException: Circular > > dependency detected in the dependency chain > > [JavaScriptReferenceHeaderItem(scope: org.apache.wicket.Application; > > name: ; locale: null; style: null; variation: null, null)]. > > JavaScriptReferenceHeaderItem(scope: org.apache.wicket.Application; > > name: ; locale: null; style: null; variation: null, null) is already > > in the chain. > > > > > > It seems that for some reason a null reference is being added to the > > header. > > > > I do not get this error in 6.5.0. > > > > Is there some obvious change i am missing between the versions that can > > point me in the right direction? > > > > > > > > -- > > Fergal Keating > > > -- Fergal Keating Senior Software Engineer --- e. fergal.keat...@directski.com p. NA *Topflight Travel Group* winter: www.directski.com www.topflight.ie www.skibeat.co.uk www.skimcneill.com summer: www.topflight.ie, www.blis <http://www.blisscamping.co.uk> scamping.co.uk <http://www.blisscamping.co.uk>
Re: wicket facebook,6.15 Circular dependency detected
Hi, I don't believe we we're getting any errors in 6.5.0. Wro4j works for our designers to allow them to add files without referencing java code. For the moment I added the various wicket javascript (minus the debugbar) to a bundle so its loaded as one file, I will look more into resourceDecoration for future reference. thanks. Fergal. On 8 May 2014 07:09, Martin Grigorov wrote: > Hi, > > What is the outcome of using new UrlResourceReference(Url.parse("")) ? > I have never thought of doing this. > I think it will produce , no ? > > The only solution I see at the moment is to use IHeaderResponseDecorator > and just skip these references. > See > > https://github.com/apache/wicket/blob/master/wicket-examples/src/main/java/org/apache/wicket/examples/resourcedecoration/ResourceDecorationApplication.java#L55for > inspiration. > > Martin Grigorov > Wicket Training and Consulting > > > On Wed, May 7, 2014 at 9:56 AM, Fergal Keating < > fergal.keat...@directski.com > > wrote: > > > Hi, > > > > I have discovered that the issue relates to how we are overriding the > > default Wicket javascript. > > > > We are adding the following to Application#init() > > > > addResourceReplacement((JavaScriptResourceReference) > > > > > DirectSkiApplication.get().getJavaScriptLibrarySettings().getJQueryReference(), > > new UrlResourceReference(Url.parse(""))); > > addResourceReplacement((JavaScriptResourceReference) > > > > > DirectSkiApplication.get().getJavaScriptLibrarySettings().getWicketEventReference(), > > new UrlResourceReference(Url.parse(""))); > > addResourceReplacement((JavaScriptResourceReference) > > > > > DirectSkiApplication.get().getJavaScriptLibrarySettings().getWicketAjaxReference(), > > new UrlResourceReference(Url.parse(""))); > > addResourceReplacement((JavaScriptResourceReference) > > > > > DirectSkiApplication.get().getJavaScriptLibrarySettings().getWicketAjaxDebugReference(),new > > UrlResourceReference(Url.parse(""))) > > > > > > We are then adding the correct resources as a bundle through wro4j.xml. > (it > > was probably overkill but trying to load as a single bundled cached > > request. > > > > This worked in wicket 6.5.0 without throwing an error. > > > > What is the simplest way i can achieve the same functionality ? > > > > > > On 6 May 2014 20:29, Martin Grigorov wrote: > > > > > Hi, > > > > > > If you are able to reproduce this in a quickstart (mini) app then > please > > > attach it to a ticket at https://issues.apache.org/jira/browse/WICKET > > > Thanks! > > > > > > Martin Grigorov > > > Wicket Training and Consulting > > > > > > > > > On Tue, May 6, 2014 at 5:43 PM, Fergal Keating < > > > fergal.keat...@directski.com > > > > wrote: > > > > > > > Hi, > > > > > > > > I was attempting to upgrade to Wicket 6.15.0 from 6.5.0 in order to > use > > > > > > > > > > > > > > > > As described in > > > > http://wicketinaction.com/2014/03/header-contributions-positioning/ > > > > > > > > This should nicely solve an issue I'm currently having in the HTML > > rather > > > > than the Java where i am using WRO4J to minimise and join javascript > > and > > > > CSS . I am also using wicket-facebook 6.15.0. > > > > > > > > I have run into a problem when i run my application. I get an error > > after > > > > facebooksdk.java line 99 The following error is thrown. > > > > > > > > org.apache.wicket.resource.CircularDependencyException: Circular > > > > dependency detected in the dependency chain > > > > [JavaScriptReferenceHeaderItem(scope: org.apache.wicket.Application; > > > > name: ; locale: null; style: null; variation: null, null)]. > > > > JavaScriptReferenceHeaderItem(scope: org.apache.wicket.Application; > > > > name: ; locale: null; style: null; variation: null, null) is already > > > > in the chain. > > > > > > > > > > > > It seems that for some reason a null reference is being added to the > > > > header. > > > > > > > > I do not get this error in 6.5.0. > > > > > > > > Is there some obvious change i am missing between the versions that > can > > > > point me in the right direction? > > > > > > > > > > > > > > > > -- > > > > Fergal Keating > > > > > > > > > > > > > > > -- > > Fergal Keating > > Senior Software Engineer > > --- > > e. fergal.keat...@directski.com > > p. NA > > > > *Topflight Travel Group* > > winter: www.directski.com www.topflight.ie www.skibeat.co.uk > > www.skimcneill.com > > summer: www.topflight.ie, www.blis <http://www.blisscamping.co.uk> > > scamping.co.uk <http://www.blisscamping.co.uk> > > > -- Fergal Keating Senior Software Engineer --- e. fergal.keat...@directski.com p. NA *Topflight Travel Group* winter: www.directski.com www.topflight.ie www.skibeat.co.uk www.skimcneill.com summer: www.topflight.ie, www.blis <http://www.blisscamping.co.uk> scamping.co.uk <http://www.blisscamping.co.uk>