cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Green <>
Subject Double Submit with forms/AJAX/HTMLArea
Date Fri, 26 May 2006 05:27:16 GMT
Hey everybody, I have an Ajax enabled form that is based on the car 
selector example with some related drop down lists which are working 
really well.  I have an option in each drop down list to "add a new 
item" which hides the drop down list, and replaces it with a text box 
and submit/cancel buttons.  These also work really well.  There's also a 
text area on the form, and whenever I try to style it as an HTMLArea 
things start acting weird. 

First when I choose the "add a new item" option from the select list it 
uses AJAX to remove the list and show the addition form.  However, when 
I click either the "Save" or "Cancel" buttons it actually submits the 
entire form (rewriting the location bar in the browser) and then only 
works correctly about half the time.  The other half of the time I get 
this exception:

java.lang.IllegalStateException: Widget Action 'newClient.cancelClient' 
that submitted the form is not active.

Cocoon stacktrace[hide]

*Error calling continuation

- 171:-1

- 0:-1
- 0:-1

- 0:-1

- 273:37
- 300:88
file:/home/jgreen/workspace/timetrack/build/timetracktest/sitemap.xmap - 

I added some debugging to Forms.js and discovered that the root of the 
problem seems to be that sometimes the form is somehow submitted twice.  
This only ever happens when using the htmlarea styling.  I was wondering 
if anyone else has seen a similar problem and knows a way around it.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message