cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Quinn <>
Subject Re: svn commit: r473974 - in /cocoon/trunk/blocks: cocoon-ajax/cocoon-ajax-impl/src/main/resources/org/apache/cocoon/ajax/resources/js/ cocoon-forms/cocoon-forms-impl/src/main/resources/org/apache/cocoon/forms/resources/ cocoon-forms/cocoon-forms-impl/src/...
Date Sun, 12 Nov 2006 15:50:51 GMT
Hi All

On 12 Nov 2006, at 15:28, wrote:

> URL:
> Log:
> Adding support for Dojo's IframeIO to CForms.
> This allows forms with file-upload fields to be submitted as a  
> background AJAX process. Currently this is turned off for Safari  
> where is is not working.

I have added support for Dojo's IframeIO AJAX Transport to CForms in  
This is to allow forms with file upload fields to be able to be  
submitted via AJAX.
This is implemented only for cforms that use JXMacro rendering  

I have tested this under Firefox, MSIE and Safari, AFAICS all samples  
that worked before the change still work. It is currently disabled in  
Safari as it does not work in the release version, however it does  
work in the nightly builds of Webkit, so hopefully it will work in  
Safari soon.

IframeIO and XMLHttp Transports do have some differences .....  
XMLHttp is completely asynchronous, IframeIO is not. Submit events in  
IframeIO get queued by Dojo as it can only handle one submit and  
response at a time, as it uses a hidden iFrame for the form.

I had a great deal of trouble getting BrowserUpdate to work reliably  
across platform and browser. I eventually had to resort to placing  
the update content inside a <textarea> and parsing it on the client.  
It looks and sounds clunky but it was the only technique I could get  
to work reliably.

While reworking the CFormsForm Widget (etc.) I was able to remove  
some functions from the CForms Libs and use functions that come with  
Dojo instead that have the same behaviour.

Another change I have made is to disable the form-control that  
submits the form, re-enabling it when the Request returns, to try to  
avoid double submits etc.

These changes need more testing !!!!

Please test Ajax and non-Ajax cforms, forms that use FormsTransformer  
as well as JXMacros.
Please look out for form controls that do not get re-enabled after  
the Request has returned.


regards Jeremy

View raw message