How to create and add custom forms to your website
Gurdeep singh
How to create and add custom forms to your website
Step-by-Step Guide
Step 1: Log In to the Admin Panel
1. Open your web browser.
2. Visit your admin panel by typing `yourwebsite.com/admin` in the address bar.
3. Enter your login credentials to access the admin dashboard.
Step 2: Create a New Form
1. In the admin panel, locate the "Forms" collection under the "Collections" section.
2. Click on the "Create New" button.
3. Add a title for the form (this title is for backend use only and not visible to front-end users).
Step 3: Add Fields to Your Form
1. Click on "+Add Field" to add fields to your form.
2. Choose from various field types:
- Text: For single-line text inputs.
- Number: For numerical inputs.
- Email: For email addresses.
- Country: For country selection.
- Select: For dropdown menus.
- Textarea: For multi-line text inputs.
- Message: To display a message within the form.
3. Configure each field, including the width (percentage between 0 to 100) to specify the field's width on the frontend.
Step 4: Configure Submission Settings
1. Select the label text for the submit button.
2. Choose the confirmation type:
- Message: Display a success message upon form submission.
- Redirect: Redirect to another page after form submission and provide the URL for the redirect.
3. Optionally, set up an SMTP server to send custom emails on form submission.
Step 5: Save the Form
1. After configuring your form, click the "Save" button.
Step 6: Add the Form to a Page
1. Navigate to the "Pages" collection.
2. Select the page where you want to add the form.
3. In the layout section, choose the form block.
4. Use the select field to choose from the forms you have created.
5. Optionally, add a title and description for the form on this page.
6. Click the "Save" button.
Viewing Your Form
- You can view your form by visiting the URL of the page where you added the form (`yourwebsite.com/slug-of-page`).
By following these steps, you can effectively create and integrate forms into your website, enhancing interactivity and user engagement.