/
add_form_step3.html
79 lines (64 loc) · 3 KB
/
add_form_step3.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
---
layout: default
navPage: docs
heading: "3: Test Submission"
breadcrumbs:
- User Documentation,/userdoc/
- Form Management,/userdoc/form_management/
- "3: Test Submission"
prev: "Step 2: Form Inforation,/userdoc/form_management/add_form_step2/"
next: "Step 4: Database Setup,/userdoc/form_management/add_form_step4/"
categories: userdoc
---
{% include open_section.html nav='nav_userdoc_form_management.html' selected='add_form_step3' nav_width=4 %}
{% include screenshot.html item='i214.jpg' %}
<p>
The test submission page is where your form first makes contact with Form Tools. It works
by waiting for a submission sent from your form that contains all the fields
you want stored. Form Tools then uses this to build a custom database table to house all
future form submissions. There are a lot of benefits to building the database table this
way, including: reducing the likelihood of errors for entering form field names,
reducing the amount of configuration required and ensuring that your form and Form Tools are
correctly connected.
</p>
<p>
Exactly how this page looks again depends on the submission method you picked on step 1.
</p>
<h3>Test Submission: Direct / POST forms</h3>
<p>
Sending a direct test submission is very simple. Honest.
</p>
<ol>
<li>Cut and paste the HTML in the textarea and replace your own <form> tag with it.
The HTML will look something like this:
{% codemirror html %}
<form action="http://www.yoursite.com/path/to/form_tools/process.php" method="post">
<input type="hidden" name="form_tools_initialize_form" value="1" />
<input type="hidden" name="form_tools_form_id" value="X" />
{% endcodemirror %}
If you indicated that this form contained a file upload field, you will see an extra
enctype="multipart/form-data" attribute. Note: if your existing form tag has other
attributes like name or onsubmit, feel free to add them to the generated code. The
important thing is that the method is set to POST and the action path is correct. The
<b>form_tools_initialize_form</b> hidden field tells Form Tools that the form data being
submitted is to be used for the test submission. The <b>form_tools_form_id</b>
hidden field is a unique number generated by the program to differentiate between the
various forms.
</li>
<li>
Now, return to your form in your browser and after refreshing the page, fill in all
fields and submit the form. Return to Form Tools and click the Refresh button in the
page, then continue to the next step.
</li>
</ol>
<h3>Test Submission: API</h3>
{% include screenshot.html item='i215.jpg' %}
<p>
Configuring your form to use the API to submit your test submission is covered in the following
tutorials:
</p>
<ul>
<li><a href="{{site.baseurl}}/tutorials/api_v2_single_page_form/">Adding a single page form with the API</a></li>
<li><a href="{{site.baseurl}}/tutorials/api_v2_multi_page_form/">Adding a multi-page form with the API</a></li>
</ul>
{% include close_section.html %}