But what happens when users are done filling out the form? There are several ways to setup Orbeon Forms, but we’ll cover here the common use case where you want to have a Submit button that:
- Saves the data in a database, per your configuration. (For more details, see which databases Orbeon Forms supports out of the box.)
- Takes users to another page.
Let’s go through those 3 properties:
<property as="xs:string" name="oxf.fr.detail.buttons.*.*" value="submit"/> <property as="xs:string" name="oxf.fr.detail.submit.buttons.*.*" value="go"/> <property as="xs:string" name="oxf.fr.detail.submit.go.uri-xpath.*.*" value="'http://www.your-site.com/form-submitted'"/>
- The first property defines which buttons are shown on the form; here we only include the Submit button, as this is the one we’re interested in, but you might want to include additional buttons.
- The second property configures the dialog that shows upon submission, which you can see in the screenshot below. Here include one button, taking users to a page of your choosing.
- The third property defines the page users are taken to. To put a static value, add single quote inside the double quotes as done here. (The value can also be dynamic: you can provide an XPath expression returning a URL, which runs on the data entered by users.)
What if this form is part of a workflow, and that depending on the data users entered, you want to take them to a different page? Then the workflow send button is what you are looking for. To end users, the workflow send button looks like a regular Submit button. But it is one that you can configure to do much more; for instance, it can:
- Optionally, generate a PDF of the form, with the data entered by users.
- Optionally, send out an email, with the XML data and/or the PDF.
- Optionally, store the XML data and/or the PDF in Alfresco.
- Take the user to a page, either sending the XML data or the PDF to that page.