Contents
Basic Form setup
- Add this form tag
<form action="https://form2channel.com" method="POST">
- Add hidden tags for form recipients (see example form) like
<input type="hidden" name="formto_googlesheets" value="me@email.address">
<input type="hidden" name="formto_email" value="me@email.address">
- Upload the page to your server
Localhost is not allowed
For submissions to Google Sheets or Email no further setup is necessary
Adding multiple forms
When adding multiple forms to one website include a form identifyer in the form action querystring like
<form action="https://form2channel.com/?form=contactus" method="POST">
<form action="https://form2channel.com/?form=customerinfo" method="POST">
Adding multiple recipients
Comma-separate multiple recipients for a channel
<input type="hidden" name="formto_email" value="me@email.address, me2@email.address">
<input type="hidden" name="formto_googlesheets" value="me@email.address, me2@email.address">
Thank you and error pages
By default the process redirects visitors to the website default page with the result in the querystring like
result={"Message":"Form submitted","Success":true}
You can add the hidden field below into your form to redirect visitors to after a successful or failed submission
<input name="formto_redirect" type="hidden" value="Url or page to redirect visitors to on success">
<input name="formto_error" type="hidden" value="Url or page to redirect visitors to on error">
File uploads
Forms that contain file upload tags must have the enctype="multipart/form-data" attribute, like so
<form action="https://form2channel.com" method="post" enctype="multipart/form-data">
Add any number of single or multiple file upload tags to the form, like so
<input type="file" name="fieldname1">
<input type="file" name="fieldname2[]" multiple>
The following limits and cautions apply to file uploads
- Max size per file: 4MB
Larger files are discarded - Max POST size: 8MB
Larger posts will fail - File retention: 30 days
Files are deleted after 30 days - File accessibility is public
All files are accessible to anyone in posession of the url - File safety not guaranteed
Files have not been scanned for viruses
Spam prevention
To prevent spamming, the following limits apply
- Up to 10 email recipients per site
You can add to these recipients every 10 days - Up to 10 Google Sheet recipients per site
You can add to these recipients every 10 days - Submitting from locally hosted pages is not permitted
Slack setup
To create a Slack webhook
- Go to https://api.slack.com/apps
- Add an app to a workspace
- Activate "Incoming Webhooks"
- Select "Add new webhook to workspace" (bottom)
- Optionally, in the "OAuth & Permissions" section you can restrict the API token usage to the Form2Channel IP address 13.79.230.33
- Add a hidden input tag to your form
<input name="formto_slack" type="hidden" value="Url of the Slack Webhook">
Telegram Setup
To get a Telegram ChatID
- Open this page on your phone and click the link
- Send /start to @Form2ChannelBot to get a ChatID
- Add a hidden input tag to your form
<input name="formto_telegram" type="hidden" value="The Chat ID the Form2Channel Telegram bot sent you">
Webhook Info
You can use the formto_http method when contacting a webhook or another API.
Add an http address into a hidden field
<input type="hidden" name="formto_http" value="Address of the receiving webhook or api">
The receiving address must accept a Json array of objects (key/value pairs) like this
[ {"key":"FirstName","value":"John"}, {"key":"LastName","value":"Lennon"}, {"key":"Country","value":"United Kingdom"}, {"key":"Subscribed","value":"checked"}, {"key":"Gender","value":"Male"}, {"key":"File","value":"https://form2channel.com/images/built-with-linx.svg"} ]
Post your data directly to our Linx REST API
You can skip the form altogether and submit your data directly to our API as a Json object
- URI: https://showcase.api.linx.twenty57.net/Form2Channel
- Method: POST
- Content Type: application/json
- Body: Array of key / value pairs as shown below
[ {"key":"formto_email","value":"me@email.address"}, {"key":"formto_email","value":"me2@email.address"}, {"key":"formto_googlesheet","value":"me@email.address"}, {"key":"FirstName","value":"John"}, {"key":"LastName","value":"Lennon"}, {"key":"Country","value":"United Kingdom"}, {"key":"Subscribed","value":"checked"}, {"key":"Gender","value":"Male"}, {"key":"File","value":"https://form2channel.com/images/built-with-linx.svg"} ]The API response consists of a Json object with two variables:
- Message (String)
- Success (boolean)
{"Message":"Form submitted","Success":true}
Spam prevention limits are applied to the calling IP address