Note that there are some explanatory texts on larger screens.

plurals
  1. POnew page forward displays old value
    text
    copied!<p>I am a beginner in Struts and got a doubt. I have got a page which redirects it to a .do file which in turn calls a struts page.</p> <p></p> <p>The above page forward calls the below specified page:</p> <p></p> <pre><code> &lt;display:table name="sessionScope.LocationLoadActionForm.loadList" class="dataTable" style="width:101%;" id="row" pagesize="5" cellspacing="0"&gt; &lt;display:column title="&lt;input type='checkbox' name='selectall' id='selectall' value='all'/&gt;"&gt; &lt;html:checkbox styleClass="case" name="LocationLoadActionForm" property="id" value="${row.locid}"/&gt; &lt;/display:column&gt; &lt;display:column property="locid" title="Location ID" media="html" /&gt; &lt;display:column property="locname" title="Location Name" group="1" sortable="true"/&gt; &lt;display:column property="loc_city" title="Location City" group="2" sortable="true" /&gt; &lt;display:setProperty name="paging.banner.full"&gt; &lt;div class="pagelinks" align="right"&gt; [&lt;a href="{1}"&gt;First&lt;/a&gt;/ &lt;a href="{2}"&gt;Prev&lt;/a&gt;] {0} [ &lt;a href="{3}"&gt;Next&lt;/a&gt;/ &lt;a href="{4}"&gt;Last &lt;/a&gt;]&lt;/div&gt; &lt;/display:setProperty&gt; &lt;display:setProperty name="paging.banner.first"&gt; &lt;div class="pagelinks" align="right"&gt; [First/Prev] {0} [ &lt;a href="{3}"&gt;Next&lt;/a&gt;/ &lt;a href="{4}"&gt;Last&lt;/a&gt;] &lt;/div&gt; &lt;/display:setProperty&gt; &lt;display:setProperty name="paging.banner.last"&gt; &lt;div class="pagelinks" align="right"&gt;[ &lt;a href="{1}"&gt;First&lt;/a&gt;/ &lt;a href="{2}"&gt;Prev&lt;/a&gt;] {0} [Next/Last] &lt;/div&gt; &lt;/display:setProperty&gt; &lt;display:setProperty name="paging.banner.onepage"&gt; &lt;div class="pagelinks" align="right"&gt; {0} &lt;/div&gt; &lt;/display:setProperty&gt; &lt;display:setProperty name="paging.banner.all_items_found" value="" /&gt; &lt;display:setProperty name="paging.banner.some_items_found" value="" /&gt; &lt;display:setProperty name="paging.banner.one_item_found" value="" /&gt; &lt;/display:table&gt; </code></pre> <p>Now there is a button which redirects to a delete page and forwards it to Locationload.do . Now when i perform the delete operation, though my record is deleted from the database however the displaytag displays the old value. How to solve the problem.</p> <p>The details of struts config file are as follows:</p> <p> </p> <pre><code> &lt;form-bean name="LocationDetailAddActionForm" type="Location.LocationDetailAddActionForm"/&gt; &lt;form-bean name="LocationLoadActionForm" type="Location.LocationLoadActionForm"/&gt; &lt;form-bean name="CountryActionForm" type="Country.CountryActionForm"/&gt; &lt;form-bean name="LocationActionForm" type="Location.LocationActionForm"/&gt; &lt;form-bean name="OrganizationActionForm" type="Organization.OrganizationActionForm"/&gt; &lt;/form-beans&gt; &lt;global-exceptions&gt; &lt;/global-exceptions&gt; &lt;action-mappings&gt; &lt;action input="/" name="OrganizationActionForm" path="/addOrganizationGeneral" scope="session" type="Organization.OrganizationAction"&gt; &lt;forward name="success" path="/Administrator/OrganizationDetail.jsp"/&gt; &lt;/action&gt; &lt;action input="/" name="CountryActionForm" path="/addCountry" scope="session" type="Country.CountryAction"&gt; &lt;forward name="success" path="/Administrator/Country.jsp"/&gt; &lt;forward name="validate" path="/Administrator/Country_validate.jsp"/&gt; &lt;/action&gt; &lt;action input="/" name="LocationActionForm" path="/addLocation" scope="session" type="Location.LocationAction"&gt; &lt;forward name="success" path="/Administrator/AdminLocation/LocationDetail.jsp"/&gt; &lt;/action&gt; &lt;action input="/" name="LocationLoadActionForm" path="/LocationLoad" scope="session" type="Location.LocationLoadAction"&gt; &lt;forward name="success" path="/Administrator/AdminLocation/LocationDetail.jsp"/&gt; &lt;/action&gt; &lt;action input="/" name="LocationDetailAddActionForm" path="/LocationAdd" scope="session" type="Location.LocationDetailAddAction"&gt; &lt;forward name="success" path="/Administrator/AdminLocation/Location.jsp"/&gt; &lt;/action&gt; &lt;action input="/" name="LocationLoadActionForm" path="/LocationDelete" scope="session" type="Location.LocationDeleteAction"&gt; &lt;forward name="success" path="/Administrator/AdminLocation/LocationDelete.jsp"/&gt; &lt;/action&gt; &lt;/action-mappings&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload