• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

How to target result Page in to tab panel.

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear Friends , I am new to JSF so it may be a trivial doubt also.

I have one main.jsp
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<html>
<head>
<link rel="stylesheet" type="text/css" href="<%=request.getContextPath()%>/css/sjx.css">
</head>
<body class="bodystylemain">
<f:view>
<rich:spacer height="20px"></rich:spacer>
<h:form>

<h anelGrid id="mainpanel" columns="2">
<rich:spacer width="190px"></rich:spacer>
<h anelGrid id="headernav" columns="5">
<rich:spacer width="600px"></rich:spacer>
<h utputText value="Welcome" styleClass="headertext"></h utputText>
<h utputText value="#{saveUserBean.user.email}" styleClass="headertext"></h utputText>
<h:graphicImage url="images/bar.gif"></h:graphicImage>
<h:commandLink value="Logout" action="#{saveUserBean.logout}" styleClass="headertext"></h:commandLink>
</h anelGrid>
</h anelGrid>
</h:form>
<rich:spacer height="200px"></rich:spacer>
<h anelGrid id="contentpanel" columns="2">
<rich:spacer width="100px"></rich:spacer>
<rich:tabPanel switchType="server" height="300px" width="1000px" tabClass="tabs" contentClass="tabcontent" headerAlignment="right" >
<rich:tab label="About Us" id="aboutus">
<jsp:include page="include/aboutus.jsp"></jsp:include>
</rich:tab>
<rich:tab label="Counselor Corner" id="counselor">
<h utputText value="If you have any query , Please write to us , Our experts are here to advise you"></h utputText>
<jsp:include page="include/inquiryform.jsp"></jsp:include>
</rich:tab>
<rich:tab label="Exchange" id="exchange">
Here is tab #3
</rich:tab>
</rich:tabPanel>
</h anelGrid>
<jsp:include page="include/footer.jsp"></jsp:include>
</f:view>

</body>

</html>

I have three tabs in that. I have one form in one tab.
When i do the submit from that tab , my result page is displayed.
The problem is I want my result page to be displayed in the same Tab container from which then form was submitted. What kind of navigation rule i need to give in faces config for this functionality.
The navigation rule is as follows:
<navigation-rule>
<description></description>
<from-view-id>/main.jsp</from-view-id>
<navigation-case>
<from-outcome>logout</from-outcome>
<to-view-id>/mytest.jsp</to-view-id>
</navigation-case>
<navigation-case>
<from-outcome>result</from-outcome>
<to-view-id>/result.jsp</to-view-id>
<redirect/>
</navigation-case>
</navigation-rule>

the result page is coming but it is coming as a different page and not loading in the tab itself.
Help will be appreciated.
Vikas
 
That is a really big piece of pie for such a tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic