logo       

Related Msgs: audio.musicbrai...    enbd.general/20...    ietf.idr/2002-0...    java.ant-contri...    gnu.make.genera...    qplus.devel/200...    video.freevo.cv...    os.netbsd.ports...    yellowdog.gener...    xfree86.cvs/200...    search.nutch.us...    freedesktop.xse...    programming.swi...    capabilities.ge...    telephony.pbx.a...    mail.sylpheed.c...    db.firebase.por...    boot-loaders.u-...    recreation.radi...    netbsd.bugs/200...    web.zope.plone....    user-groups.lin...   

Re: RE : Accessing xforms-submit-error: msg#00003

Subject: Re: RE : Accessing xforms-submit-error
Adrian Baker wrote:
Well the first problem with this approach is that if you have an error
in your getErrors submission, you end up with a stack overflow, because
it will generate another xforms-submit-error event, causing getErrors to
be called again, and so on.

The fix for this would be to introduce an ev:target attribute onto my
action :

<action ev:event="xforms-submit-error" ev:target="save">
     <send submission="getErrors"/>
</action>

So that a further xforms-submit-error from the getErrors submission
won't end up in this block. But, it seems the target & observer
attributes are not used in Chiba, only the event attribute...
yes. right. the XMl events support is still not complete.

additionally i think access to submission errors should be available to XForms in a more direct way (even your approach is quite creative). this problem has been discussed several times before (also on the official XForms list). hope it will be addressed in 1.1 in a straightforward way.

Joern

Adrian


-----Original Message-----
From: Adrian Baker Sent: Monday, 28 February 2005 5:33 p.m.
To: chiba-developer-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
Subject: RE : Accessing xforms-submit-error

As a workaround I was planning to store the errors on the 'real' server in the session, and then have a handler on the xforms-submit-error element which would retrieve this with a 'server-side' lookup. Something like :

<xforms:instance id="notifications" xmlns="">
        <notifications>
                <errors>
<error>(template error notification message)</error>
                </errors>
                                                
                <messages>
<message>(template notification message)</message>
                </messages>
        </notifications>          
</xforms:instance>
...
<submission id="getErrors" replace="instance" ref="instance('notifications')/errors" .../> ... <action ev:event="xforms-submit-error">
   <send submission="getErrors"/>
</action>

The notifications instance data is then bound to a nice pretty repeating notifications area on the top of the form :)

All that remains is getting the server to provide the error messages as the submit reply... I guess the proper portable way to do this is XMLRPC? Could I run into any session issues using this?

Adrian
(sorry for 'fake' reply - this message never made it to my client, so I had to cut & paste from sourceforge).



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_ide95&alloc_id396&op=click
_______________________________________________
Chiba-developer mailing list
Chiba-developer-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/chiba-developer




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click



Try Searching:
servers, voip, java, networking, microsoft ...
<Prev in Thread] Current Thread [Next in Thread>