Re: [Xsltforms-support] Problem with replace all
Brought to you by:
alain-couthures
From: COUTHURES A. <ala...@ag...> - 2010-01-29 17:15:35
|
Hello, > I think this is an XSLTForms limitation of submission replace='all', but of course Alain would have to answer that. > The required instructions to interpret an XSLT processing-instruction (such as the one for applying xsltforms.xsl !) in the return of the submission are not yet implemented. > I believe the problem is because replace='all' uses XHR, even when method='get'. > XmlHttpRequest is the only way to manage errors, if any, from the initial XForms document. > You can use an XSLTForms-only hack for POST, by doing method="xml-urlencoded-post". In this case, XSLTForms creates an HTML4 form and serializes the XML into a single HTML4 field named "postdata." The disadvantge is that you must alter server-side code to look for a URL Encoded POST containing a parameter "postdata" and then extract that and parsing it as XML. This hack was easy to implement. It guarantees that the browser knows it is a completely new page so memory leak should be under control. But there is no error management... By the way, at server-side, it is not necessary to check if the parameter is named "postdata" or anything else... > > > Personally, I think that XSLTForms could similarly implement submission method='get' when replace='all' by creating an HTML form element, and there would be no compensation needed and your example below would work. I consider that xf:load is better for that usage. > Perhaps Alain has already explored this and found it unworkable for some reason, or perhaps it is just work that needs doing (and maybe you could help?) > There is still plenty of work that needs doing in XSLTForms ! Thanks! -Alain |