aspose file tools*
The moose likes JSF and the fly likes Session  Synchronization Problem in JSF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Session  Synchronization Problem in JSF" Watch "Session  Synchronization Problem in JSF" New topic
Author

Session Synchronization Problem in JSF

umesh annegirikar
Greenhorn

Joined: May 09, 2011
Posts: 28
hello..
I am working on the JSF 2.0 in our web application we facing the problem of the component rendering.
we provided the two buttons next and back for navigating from one page to next page when user logs in the while clicking next it goes to next page on that it performs some operations then when it clicks on the back button it comes to previous page again but if user again click the next button it never goes to next page though customer is logged in.
somtime it takes the two times click go to next page...
I am a newbie to the JSF,richfaces 4.0,Spring.
So please tell us the problem
The code in which i working is


<div xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:a4j="http://richfaces.org/a4j"
xmlns:rich="http://richfaces.org/rich">

<h:form>
<script type="text/javascript">
function loadnext(divout,divin)
{
$("." + divout).hide();
$("." + divin).fadeIn("fast");
}
</script>

<rich:panel>
<div id="wizardwrapper">
<div class="1">
<ul id="mainNav" class="fiveStep">
<li class="current">1.Scope Options </li>
<li>2.Target Identification </li>
<li>3.Market Scope</li>
<li>4.Potential Analysis</li>
<li class="mainNavNoBg">5.Leads Delivery</li>
</ul>
</div>
</div>
</rich:panel>

<table align="center">
<tr>
<td>
<a4j:commandButton image="/image/back.png" action="#{manageBean.getProjectList}" style="font-size:16px; margin-left:10px" immediate="true">
<f:param name="VALIDATE" value="false" />
</a4j:commandButton>
</td>
<td style="width: 1200px"></td>
<td style="width: 1200px"></td>
<td style="width: 40px"></td>
<td>
<a4j:commandButton image="/image/next.png" action="#{manageBean.getCustomerList}" immediate="true" limitRender="2">
<f:param name="VALIDATE" value="false" />
</a4j:commandButton>
</td>
</tr>
</table>

<rich:panel align="center" height="100%">
<rich:messages ajaxRendered="true" />
<table align="center" cellspacing="20" cellpadding="10" >
<tr>
<td>
<hutputText value="Project Name:" style="font-size: 16px" />
</td>
<td>
<h:inputText id="ProjectName" value="#{manageBean.projectName}" required="true" style="font-size: 14px; width: 150px;">
<rich:message for="ProjectName" ajaxRendered="true"/>
</h:inputText>
</td>
<td>
<h:selectOneRadio value="#{manageBean.customerList}" layout="pageDirection">
<f:selectItem itemValue="1" itemLabel="You have customer list">
</f:selectItem>
<f:selectItem itemValue="0" itemLabel="You do not have customer list">
</f:selectItem>
</h:selectOneRadio>
<h:selectBooleanCheckbox value="" disabled="true"/><hutputText value=" "/>Define ideal customers based on company profiles<br/>
<hutputText value=" " />
<hutputText value=" " />
<h:selectBooleanCheckbox value="" disabled="true"/><hutputText value=" "/>Define ideal customers based on web site content
</td>
</tr>
<tr>
<td>
<hutputText value="Number of leads needed:" style="font-size: 16px" />
</td>
<td>
<h:inputText id="NumberofLeads" value="#{manageBean.numberLeads}" style="font-size: 14px; width: 150px;" required="true">
<rich:message for="NumberofLeads" ajaxRendered="true"/>
</h:inputText>
</td>
<td>
<hutputText value=" " />
</td>
</tr>
<tr>
<td>
<hutputText value="Project Description" style="font-size:16px"/>
</td>
<td>
<h:inputTextarea id="ProjectDescription" value="#{manageBean.description}" required="true" style="font-size: 14px; width: 250px; height: 100px;">
<rich:message for="Project Description" ajaxRendered="true"/>
</h:inputTextarea>
</td>
<td>
<h:selectBooleanCheckbox value="#{manageBean.potentialAnalysis}"/><hutputText value=" " />Member Potential Analysis
</td>
</tr>
<tr>
<td colspan="3">
<hutputText value=" " />
</td>
</tr>
<tr>
<td colspan="3">
<hutputText value=" " />
</td>
</tr>
<tr>
<td colspan="3" align="center">
<h:commandButton value="Save" action="#{manageBean.save}" style="font-size:16px; margin-left:10px">
</h:commandButton>
</td>

</tr>
</table>
</rich:panel>

</h:form>
</div>

So please help me...

Thanking you...
Regards
Umesh


 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Session Synchronization Problem in JSF