hi orbeon users
how can i automatically start a submission after the page is shown. i want to show the page first and the load some additional data (slow to calculate) in the background. i tried the xforms:send function in the model with the xforms-ready event, but the event is fired before the page is loaded/presented. <xforms:send submission="mySubmission" ev:event="xforms-ready"/> is there another event i didn't find or how can i do that? i'm using orbeon 3.5 thanks. markus -- Markus Kinzler NETBREEZE GmbH Mail [hidden email] Ringstrasse 12 Tel +41 44 824 32 51 CH-8600 Duebendorf Web http://www.netbreeze.ch Switzerland -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Administrator
|
Markus,
I attached an improved version of our small "Custom Events" sample, which shows exactly how to do this. Here is how it works: * Upon XForms initialization, the XForms model receives the event xforms-ready. This happens before the page is sent to the web browser. * The event handler for xforms-ready executes the extension xxforms:script action which allows running JavaScript code on the client. * Just after the page is loaded in the browser, the xxforms:script action runs in the web browser and executes its JavaScript content. * The JavaScript dispatches a custom XForms event to the XForms model. The event is sent from the web browser to the XForms engine on the server. The event here is called acme-super-event and must be explicitly allowed on the model using the xxforms:external-events property, for security reasons. * The event reaches the XForms model on the server. An event handler for xxforms:external-events causes a message to be displayed on the client. In your case, instead of displaying a message, you would run your submission. -Erik On Feb 15, 2008, at 6:50 AM, Markus Kinzler wrote: > hi orbeon users > > > > how can i automatically start a submission after the page is shown. > i want to show the page first and the load some additional data > (slow to calculate) in the background. > > i tried the xforms:send function in the model with the xforms-ready > event, but the event is fired before the page is loaded/presented. > > <xforms:send submission="mySubmission" ev:event="xforms-ready"/> > > > is there another event i didn't find or how can i do that? > > i'm using orbeon 3.5 > > > > thanks. markus > > > -- > Markus Kinzler NETBREEZE GmbH > Mail [hidden email] Ringstrasse 12 > Tel +41 44 824 32 51 CH-8600 Duebendorf > Web http://www.netbreeze.ch Switzerland > > > -- > You receive this message as a subscriber of the [hidden email] > mailing list. > To unsubscribe: mailto:[hidden email] > For general help: mailto:[hidden email]?subject=help > OW2 mailing lists service home page: http://www.ow2.org/wws Orbeon Forms - Web Forms for the Enterprise Done the Right Way http://www.orbeon.com/ -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws custom-events.xhtml (3K) Download Attachment |
Free forum by Nabble | Edit this page |