what is your filter mapping?

-igor

On Mon, Mar 9, 2009 at 6:00 PM, qssdy <[email protected]> wrote:
>
> Wicket version: 1.4-rc1
>
> Hi,
>
>     I'm very new to Wicket, so I'm probably making a simple mistake that I
> overlooked.  Thank you for your insights ahead of time.
>
>     I have a small wicket application consisting of about 8-10 pages -
> interconnected by ~50% links and ~50% form submissions.
>
>     Now everything was (is) fine until I mounted the single package
> containing all of my web pages.  Then all of my links in the application are
> converted from the Wicket default (e.g.
> http://localhost:8080/?wicket:bookmarkablePage=:my.package.MyPage) to the
> mounted format (e.g. http://localhost:8080/pages/MyPage/).  That much is
> fine; all the links still work.
>
>     However, none of my form submissions work - they all result in
> PageExpiredException (no form or button onSubmit() methods are called) and
> are redirected to the page expired error page.  I have done some debugging,
> and it seems to me that the problem lies in the fact that
>
> org.apache.wicket.Session: line 771
> pageMap.get(Integer.parseInt(id), versionNumber);
>
> returns null.
>
>     Interestingly, I tested whether Wicket still understands its
> default/canonical URL form by going to
> http://localhost:8080/?wicket:bookmarkablePage=:my.package.MyPage directly
> via the browser URL field.  That works, and what's more, immediately after
> that, all my form submissions work and pageMap.get() returns a valid Page!
>
>     To me this seems like the Application may need to be initialized
> somehow that I am not doing, or perhaps I am calling the mount() method at
> the wrong time.  Here are code snippets for my custom application:
>
> package my.package;
>
> import org.apache.wicket.protocol.http.WebApplication;
> import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
>
> public class MyApplication extends WebApplication {
>        public MyApplication() {
>        }
>
>       �...@override
>        public void init() {
>                addComponentInstantiationListener(new 
> SpringComponentInjector(this,
> mySpringApplicationContext));
>                
> getApplicationSettings().setPageExpiredErrorPage(MyExpiredPage.class);
>                
> getApplicationSettings().setAccessDeniedPage(MyAccessDeniedPage.class);
>                
> getApplicationSettings().setInternalErrorPage(MyInternalErrorPage.class);
>
> getExceptionSettings().setUnexpectedExceptionDisplay(IExceptionSettings.SHOW_INTERNAL_ERROR_PAGE);
>                mount("pages", PackageName.forClass(MyPage.class));
> //              mountBookmarkablePage("MyPage", MyPage.class);
>        }
> }
>
>        Interestingly, the code (and forms) works if I uncomment the line that 
> only
> mounts a single page and comment out the previous line that mounts the
> entire package.
>
>        Thanks again for any help you can offer!
> --
> View this message in context: 
> http://www.nabble.com/PageExpiredException-after-mounting-WebPage-package-tp22426042p22426042.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]

Reply via email to