当前位置: 动力学知识库 > 问答 > 编程问答 >

Wicket Pagemap Correct Use

问题描述:

I'm working on an app. with a homepage that contains two iframes. Each one of these iframes is refreshed every 5 seconds. Also, from the homepage the user can open several popup windows. Right now, when I open one of the popup windows, and reload it 3 or 4 times, one of the iframes in the homepage crashes because of a PageExpiredException. My question is, what would be the right way to use PageMaps to avoid this PageExpiredException? Also, the back button won't be available, so I don't need to keep previous versions of any page in session, is there a way to tell app. not to store previous versions of the pages?

Thanks,

Juan.

网友答案:

Each window, frame or iframe should have a PageMap of its own, so they don't conflict with each other. When you create the initial URL of an iframe, use the urlFor(PageMap,Class,PageParameter) method, so that page and pages navigated from there are part of that PageMap.

Stateless pages don't go into the PageMaps, so if a window only shows stateless pages, it doesn't really matter what is its PageMap (you may use the default).

If you upgrade to Wicket 1.5 (in RC right now), you don't have to worry about that anymore, since they discarded the whole PageMaps concept.

分享给朋友:
您可能感兴趣的文章:
随机阅读: