You can either set theme="ajax" on the submit, or on the form, and add a
"notifyTopic" to the submit tag. Topics there will be executed twice, one
before and one after the request, it is documented on the ajax page. The
topic receives 3 parameters and one of them is an string which will be
"before" for the before-request-callback, and "load" for the
after-request-callbak. On 2.1 I added a beforeNotifyTopic, and
afterNotifyTopic to simplify this.
On 2.0.X you will have to do something like:
dojo.event.topic.subscribe("/request", function(data, type, request) {
if(type == "load") {
//reload your div
dojo.topic.publish("/refresh")
}
});
<s:url
id="ajaxTest"
value="/AjaxTest.action" />
<s:submit
type="submit"
theme="ajax"
value="submit"
notifyTopics="/request"
href="%{ajaxTest}"/>
musachy
On 4/3/07, Dave Newton <[EMAIL PROTECTED]> wrote:
--- Dave Newton <[EMAIL PROTECTED]> wrote:
> This is actually "working" except that the
> fileListDiv updates with:
Minor update:
...
<s:submit notifyTopics="/updateFileList"/>
...
<s:div href="%{...}"
listenTopics="/updateFileList".../>
almost works but the div updates itself twice; once
immediately and once again after the form submission
completes (I assume).
d.
____________________________________________________________________________________
8:00? 8:25? 8:40? Find a flick in no time
with the Yahoo! Search movie showtime shortcut.
http://tools.search.yahoo.com/shortcuts/#news
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
--
"Hey you! Would you help me to carry the stone?" Pink Floyd