Wicket中的问题

时间:2009-07-22 04:48:44

标签: java frameworks wicket

我有一个名为BranchMap的页面,它使用GoogleMap在用户登录后向用户显示一些建筑物。 数据最初是受保护的(需要密码)情况(在扩展ProtectedPage的CategoiresXML中)但我发现谷歌无法登录系统并使页面从WebPage扩展。 但现在当我进入BranchMap页面并按CTRL + F5页面过期时,我指的是HomePage。 有谁知道原因?如果你想要更多信息告诉我把它们放进去。

1 个答案:

答案 0 :(得分:2)

不完全确定你所描述的内容 - 它不是很清楚,但看看这是否有帮助:

当某些Ajax调用导致页面发生更改时,可能会发生这种情况,但刷新页面(不可收藏),其URL指的是过期版本会导致此异常。我有一个问题,当我们有多个iframe调用我们的wicket应用程序时(抱歉模糊的解释 - 就在不久之前)。

最后,对于我们的应用程序,我们必须将不同的iframe源分成web.xml中的不同servlet - 以便完全隔离不同页面的会话 - 但这是另一个故事。

尝试将此添加到您的wicket应用程序init方法。

// debug code for fixing session issue (multiple ajax using pages inside
// one browser)
get().getPageSettings().setAutomaticMultiWindowSupport(true);

并查看此处的文档:http://wicket.apache.org/docs/1.4/org/apache/wicket/jmx/PageSettings.html#getAutomaticMultiWindowSupport()

你能显示堆栈跟踪吗?

您使用的是什么版本的Wicket?

在1.4-rc3之前的javadoc中还有一些错误的通信,在这里补丁: http://svn.apache.org/viewvc/wicket/trunk/wicket/src/main/java/org/apache/wicket/settings/IPageSettings.java?r1=647167&r2=768578&pathrev=768578&diff_format=h

此处的问题:https://issues.apache.org/jira/browse/WICKET-2233

以下是来自IPageSettings的javadoc中的更新注释:

/**
 * Gets whether Wicket should try to support opening multiple windows for the same session
 * transparently. If this is true - the default setting -, Wicket tries to detect whether a new
 * window was opened by a user (e.g. in Internet Explorer by pressing ctrl+n or ctrl+click on a
 * link), and if it detects that, it creates a new page map for that window on the fly. As a
 * page map represents the 'history' of one window, each window will then have their own
 * history. If two windows would share the same page map, the non-bookmarkable links on one
 * window could refer to stale state after working a while in the other window.
 * <p>
 * <strong> Currently, Wicket trying to do this is a best effort that is not completely fail
 * safe. When the client does not support cookies, support gets tricky and incomplete. See
 * {@link WebPage}'s internals for the implementation. </strong>
 * </p>
 * 
 * @return Whether Wicket should try to support multiple windows transparently
 */
boolean getAutomaticMultiWindowSupport();