We have the following code (listed below) in our JSP. We are seeing the action configured in the href of the div id=pwcercontainer being called twice. Can’t work out exactly why. Replacing the containing sx:div label='Admin Record Deployment' with a plain non-struts div causes the action to be called only once. We can’t see anything in the documentation for sx:div that explains this behavior.
Does anyone know anything about this or have similar experience?
Thanks. NCF
<%@ page language='java' %> <%@ taglib uri='/WEB-INF/tags/c.tld' prefix='c' %> <%@ taglib prefix='s' uri='/struts-tags' %> <%@ taglib uri='http://tiles.apache.org/tags-tiles' prefix='tiles' %> <%@ taglib uri='/WEB-INF/tags/arcade.tld' prefix='arcade' %> <%@ taglib prefix='sx' uri='/struts-dojo-tags' %> <s:url id='pwcerAjax' action='pwcerajax' method='start' includeParams='none'/> <s:url id='pwAjax' action='pwajax' method='start' includeParams='none'/> <s:url id='listPendingDeploymentsLink' action='listPendingDeployments' namespace='/'/> <s:url id='record' action='recordDeploymentFragment' method='showAdminRecord' namespace='/'/> <sx:div label='Admin Record Deployment' > <!-- Div where content will be displayed --> <sx:div id='pwcercontainer' href='%{pwcerAjax}' showLoadingText='false' indicator='recordImage' preload='true'> </sx:div> <div id='loadingContainer'><img id='recordImage' src='images/ajaxLoadingAnimation.gif' style='display:none' alt='loading animation'/></div> </sx:div>
I have hit this issue many times now and it is always down to an error on my part. Either returning a fragment that contains the calling piece of code:
Or i have been setting the target attribute of another ajax tag to be an sx:div when I really should be updating it using a dojo topic.
Hope this helps somebody
Neil