English 中文(简体)
从jsf页面或从有管理的星号上向上页导航
原标题:Navigation to previous page from jsf page or from managed bean page

I m 采用JF2.0。 在用户点击适当的纽顿时,我还要执行将用户送回原网页。 此外,我不想使用javascript和jquery。 请允许我提出任何建议。 提前感谢。

问题回答

您可以尝试在你管理的灯塔中使用这种方法:

    public void back()
    {
            FacesContext.getCurrentInstance().getExternalContext().redirect("login.xhtml");
    }

If you are using JSF 1.1-1.2:
You can set the config.xml file something like that:

<navigation-case> 
    <from-outcome>previous</from-outcome>
    <to-view-id>/jsp/previous.xhtml</to-view-id>
</navigation-case>

你们可以叫回来。 以往职能:

public String returnPrevious() {
    return "previous"; 
}

Since JSF 2.0 you can do it more easier, look at this link:
http://www.mkyong.com/jsf2/implicit-navigation-in-jsf-2-0/





相关问题
combining flipsideview and navigationview

when i am trying to combine flipsideview and navigation view i am getting following error "request for member delegate is something not in a structure or union" on the line controller.delegate = ...

Rails category navigation with tags

I want to create a navigation system for my web application where there are several main categories for articles and several sub tags for each category. For example, in category "Writing" there might ...

Wordpress Navigation

I am working on a Wordpress Theme, I need to work on the navigation, I am having a little trouble creating it. The navigation I am looking for looks like this: www.neu.edu/humanities. I have gotten ...

Silverlight cant find page error

I have started a a new project (to refactor some code), and just can t work out why I keep getting "Can t find page /Index" error. The code works fine until I use an add method (on any collection ...

Zend Framework - multiplate navigation blocks

I want to use the navigation helper to build my navigation menus using Acl. The Acl part I have working fine. I now want to be able to display a few different types of navigation. E.g. admin-nav, ...

Creating a Web Navigation Helper Class for MVC

Im a newbie to MVC and trying to use the web navigator class in my MVC application. http://polymorphicpodcast.com/shows/webnavigator/ The class enables us to have stongly typed urls in a central class ...

热门标签