Re: [Wicket-user] Pretty URL for login page ?
* Johan Compagner: > Please make a RFE I created a patch because I need it too: See http://sourceforge.net/tracker/index.php?func=detail&aid=1538810&group_id=119783&atid=684977 -- Jean-Baptiste Quenot aka John Banana Qwerty http://caraldi.com/jbq/ - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Pretty URL for login page ?
Please make a RFEOn 8/11/06, Ingram Chen <[EMAIL PROTECTED]> wrote: Thanks for fast reply!If this is feasible I will create a RFE for this change. hope we'll have this feature next release :-) On 8/11/06, Johan Compagner <[EMAIL PROTECTED]> wrote: Mounting like Gwyn proposed doesn't work either.The problem is that we always redirect to an instance because of the pagemap method: final void redirectToInterceptPage(final Page page) { // Get the request cycle final RequestCycle cycle = RequestCycle.get(); // The intercept continuation URL should be saved exactly as the // original request specified. interceptContinuationURL = cycle.getRequest ().getURL(); // Page map is dirty session.dirtyPageMap(this); // Redirect to the page cycle.setRedirect(true); cycle.setResponsePage(page); }Maybe we should also make redirecting to a class: final void redirectToInterceptPage(final Class pageClass) { // Get the request cycle final RequestCycle cycle = RequestCycle.get(); // The intercept continuation URL should be saved exactly as the // original request specified. interceptContinuationURL = cycle.getRequest().getURL(); // Page map is dirty session.dirtyPageMap(this); // Redirect to the page cycle.setRedirect(true); cycle.setResponsePage(pageClass); }then you will get a bookmarkable url or a mount url.johan On 8/11/06, Ingram Chen <[EMAIL PROTECTED]> wrote: All, This small problem annoys us very long time:When I first reach http://mycompany.com, with normal configuration, we check if user login or not and throw RestartResponseAtInterceptPageException( IndexPage.class)to redirect user to Login page. This work perfectly but the URL become unstable link like: http://mycompany.com/app?wicket:interface=:1 ::Normally user want to bookmark login page, but in this case such URL does not work at all.Is there any way to fix this 'problem' ? It would be better I could redirect to root context like http://mycompany.com/ or http://mycompany.com/appThanks in advance!-- Ingram ChenJava [EMAIL PROTECTED]Institue of BioMedical Sciences Academia Sinica Taiwan blog: http://www.javaworld.com.tw/roller/page/ingramchen -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user -- Ingram ChenJava [EMAIL PROTECTED]Institue of BioMedical Sciences Academia Sinica Taiwanblog: http://www.javaworld.com.tw/roller/page/ingramchen -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Pretty URL for login page ?
No we are marking the PageMap as dirtyand that is the case:interceptContinuationURL = cycle.getRequest().getURL();that field of pagemap is updated...johan On 8/11/06, Jean-Baptiste Quenot <[EMAIL PROTECTED]> wrote: * Johan Compagner:>> Maybe we should also make redirecting to a class:>>final void redirectToInterceptPage(final Class pageClass)>{>// Get the request cycle>final RequestCycle cycle = RequestCycle.get();>>// The intercept continuation URL should be saved exactly as the>// original request specified.>interceptContinuationURL = cycle.getRequest().getURL(); >>// Page map is dirty>session.dirtyPageMap(this);Do you think it is really necessary to update the session'sPageMap? I think if we use a Class, there is no need for marking the session dirty.-- Jean-Baptiste Quenotaka John Banana Qwertyhttp://caraldi.com/jbq/- Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easierDownload IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing listWicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Pretty URL for login page ?
* Johan Compagner: > > Maybe we should also make redirecting to a class: > >final void redirectToInterceptPage(final Class pageClass) >{ >// Get the request cycle >final RequestCycle cycle = RequestCycle.get(); > >// The intercept continuation URL should be saved exactly as the >// original request specified. >interceptContinuationURL = cycle.getRequest().getURL(); > >// Page map is dirty >session.dirtyPageMap(this); Do you think it is really necessary to update the session's PageMap? I think if we use a Class, there is no need for marking the session dirty. -- Jean-Baptiste Quenot aka John Banana Qwerty http://caraldi.com/jbq/ - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Pretty URL for login page ?
Thanks for fast reply!If this is feasible I will create a RFE for this change. hope we'll have this feature next release :-)On 8/11/06, Johan Compagner <[EMAIL PROTECTED]> wrote: Mounting like Gwyn proposed doesn't work either.The problem is that we always redirect to an instance because of the pagemap method: final void redirectToInterceptPage(final Page page) { // Get the request cycle final RequestCycle cycle = RequestCycle.get(); // The intercept continuation URL should be saved exactly as the // original request specified. interceptContinuationURL = cycle.getRequest ().getURL(); // Page map is dirty session.dirtyPageMap(this); // Redirect to the page cycle.setRedirect(true); cycle.setResponsePage(page); }Maybe we should also make redirecting to a class: final void redirectToInterceptPage(final Class pageClass) { // Get the request cycle final RequestCycle cycle = RequestCycle.get(); // The intercept continuation URL should be saved exactly as the // original request specified. interceptContinuationURL = cycle.getRequest().getURL(); // Page map is dirty session.dirtyPageMap(this); // Redirect to the page cycle.setRedirect(true); cycle.setResponsePage(pageClass); }then you will get a bookmarkable url or a mount url.johan On 8/11/06, Ingram Chen <[EMAIL PROTECTED]> wrote: All, This small problem annoys us very long time:When I first reach http://mycompany.com, with normal configuration, we check if user login or not and throw RestartResponseAtInterceptPageException( IndexPage.class)to redirect user to Login page. This work perfectly but the URL become unstable link like: http://mycompany.com/app?wicket:interface=:1 ::Normally user want to bookmark login page, but in this case such URL does not work at all.Is there any way to fix this 'problem' ? It would be better I could redirect to root context like http://mycompany.com/ or http://mycompany.com/appThanks in advance!-- Ingram ChenJava [EMAIL PROTECTED]Institue of BioMedical Sciences Academia Sinica Taiwan blog: http://www.javaworld.com.tw/roller/page/ingramchen -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user -- Ingram ChenJava [EMAIL PROTECTED]Institue of BioMedical Sciences Academia Sinica Taiwanblog: http://www.javaworld.com.tw/roller/page/ingramchen - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Pretty URL for login page ?
Mounting like Gwyn proposed doesn't work either.The problem is that we always redirect to an instance because of the pagemap method: final void redirectToInterceptPage(final Page page) { // Get the request cycle final RequestCycle cycle = RequestCycle.get(); // The intercept continuation URL should be saved exactly as the // original request specified. interceptContinuationURL = cycle.getRequest ().getURL(); // Page map is dirty session.dirtyPageMap(this); // Redirect to the page cycle.setRedirect(true); cycle.setResponsePage(page); }Maybe we should also make redirecting to a class: final void redirectToInterceptPage(final Class pageClass) { // Get the request cycle final RequestCycle cycle = RequestCycle.get(); // The intercept continuation URL should be saved exactly as the // original request specified. interceptContinuationURL = cycle.getRequest().getURL(); // Page map is dirty session.dirtyPageMap(this); // Redirect to the page cycle.setRedirect(true); cycle.setResponsePage(pageClass); }then you will get a bookmarkable url or a mount url.johanOn 8/11/06, Ingram Chen <[EMAIL PROTECTED]> wrote: All, This small problem annoys us very long time:When I first reach http://mycompany.com, with normal configuration, we check if user login or not and throw RestartResponseAtInterceptPageException( IndexPage.class)to redirect user to Login page. This work perfectly but the URL become unstable link like: http://mycompany.com/app?wicket:interface=:1 ::Normally user want to bookmark login page, but in this case such URL does not work at all.Is there any way to fix this 'problem' ? It would be better I could redirect to root context like http://mycompany.com/ or http://mycompany.com/appThanks in advance!-- Ingram ChenJava [EMAIL PROTECTED]Institue of BioMedical Sciences Academia Sinica Taiwan blog: http://www.javaworld.com.tw/roller/page/ingramchen -Using Tomcat but need to do more? Need to support web services, security?Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___Wicket-user mailing list Wicket-user@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/wicket-user - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user
Re: [Wicket-user] Pretty URL for login page ?
I haven't tried it, but I wonder if something like mountBookmarkablePage("/login", LoginPage.class); in your Application instance would give what you want? Note, it's probably a bad idea to try & duplicate 'real' pages/folders such as "/" or "/app"! Having said that though, I'd have thought youd be better off just telling the users to bookmark the IndexPage when they get there? That way, if they go back to the URL after just having been logged in, they get there, whereas if they've not been there for a while, they'll get sent to the login page anyway. /Gwyn On 11/08/06, Ingram Chen <[EMAIL PROTECTED]> wrote: > All, > >This small problem annoys us very long time: > > When I first reach http://mycompany.com, with normal configuration, we > check if user login or not and throw > RestartResponseAtInterceptPageException( IndexPage.class) > to redirect user to Login page. > > This work perfectly but the URL become unstable link like: > > http://mycompany.com/app?wicket:interface=:1 :: > > Normally user want to bookmark login page, but in this case such URL does > not work at all. > > Is there any way to fix this 'problem' ? It would be better I could redirect > to root context like > http://mycompany.com/ or http://mycompany.com/app -- Download Wicket 1.2.1 now! - http://wicketframework.org - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user