Orbeon Forms
Search…
Services

Introduction

Form Runner supports implementing services using XPL (the XML pipeline language), associated with an application or a specific form.
NOTE: This is an advanced feature which requires programming.

Mapping an XPL file to a service URL

Assuming the following:
  • App name: acme
  • Form name: order
If you place a file called foo.xpl under
1
WEB-INF/resources/form/acme/service/
Copied!
A service called foo is made available the following URL:
1
/fr/service/custom/acme/foo
2
`
Copied!
Similarly, if you place a file called bar.xpl under
1
WEB-INF/resources/form/acme/order/service/
Copied!
A service called bar is made available the following URL:
1
/fr/service/custom/acme/order/bar
2
`
Copied!

Implementation of the service

The XPL has the following interface:
  • instance input: contains the XML data posted to the service URL
  • data output: XML data produced by the service
The following example XPL just echoes the incoming data:
1
<p:config
2
xmlns:p="http://www.orbeon.com/oxf/pipeline"
3
xmlns:oxf="http://www.orbeon.com/oxf/processors">
4
5
<p:param type="input" name="instance"/>
6
<p:param type="output" name="data"/>
7
8
<p:processor name="oxf:identity">
9
<p:input name="data" href="#instance"/>
10
<p:output name="data" ref="data"/>
11
</p:processor>
12
13
</p:config>
Copied!