The Webforms feature allows you to collect information from anonymous site visitors. Uses for this feature include surveys, multi-page questionnaires, polls, event registration forms, and lead generation pages.
Forms features a basic analysis of the results collected. If this is insufficient, you can download the data off your site for further analysis and use in any spreadsheet.
For information about viewing the results of your webforms, see Webform results.
Webform typically is used when performing data collection that is a one-way communication, that is, many users submitting values to a very small set of administrators. Webform is not a front end for letting users create custom nodes. Webform submissions are not nodes. This means that you can't use Views with submissions, setup custom access permissions to submissions, or do just about anything with them outside of what Webform provides for you.
Webform components are basically the equivalent of CCK fields. You can add any number of fields to a node that an end-user can fill out. All components are included with the Webform module. These include:
To read how to make checkboxes, radio buttons/groups, and menus/lists then read the Webform Field Types portion of this doc.
To create a new webform:
Survey
.Adding the first field into the editing area automatically adds a Submit button to the webform.
You can rearrange the fields at any time during the webform creation process.
Drupal Gardens creates the webform based on your settings. To view the created webform, in the admin menu, select Find content.
Each field that you select for your webform has additional attributes that you can modify in order to ensure that you're collecting the required information from the person filling out the form.
When you select a displayed field in the webform in order to edit it, the field's attributes appear on the left of the page in the Field settings tab. For each field, the Field settings tab contains an accordion view of that field's Properties, Display, and Validation attributes.
Text field
A single-line text entry field.
Multi-line text field
A multi-line text entry field.
Radio buttons
Obtains a single choice from a list of items.
Check boxes
Obtains one or more choices from a list of items.
Drop-down list
Obtains a single choice from a list of items.
E-mail
Only accepts valid e-mail addresses as input.
File upload
Allow visitors to include files as part of their submission. You can use this for users to include photographs, music, documentation, resumes and more.
Page break
Insert one or more page breaks to create a multi-page form. This can help you keep question pages short and simple.
Formatted content
Enter explanatory texts, instructions, images and so on. To format and organize the text, select a text format and use the HTML formatting it supports.
Fieldset
Organize fields into groups on the page. Simply drag a fieldset into place, then drag one or more fields into it.
Hidden field
This field and its contents are not visible to your site visitors. You can use it to label results from different forms, different versions of the same form, add reminders to site admins about processing deadlines or anything else you need. Setting a default value will return it with the rest of the results submitted by your site visitors, such as a survey version number.
The panels at the bottom of the webform page include several customization options for the webform.
The Form settings panel provides customization options specific to webforms, including how they handle user data submissions, access, and other advanced settings.
For information about the other available panels on the page, see Common content settings.
Select from the following form submit options in the drop-down menu:
For more information about Mollom, see Mollom. This check box is enabled by default.
When you select this check box, additional settings appear which allow you to set a visitor's number of allowed submissions for a period of time.
When you select this check box, additional fields appear for the email message:
Use this section to set which user roles can access and submit your form. For more information about user roles, see User roles and permissions.
Tokens allow you to configure the notification email for each webform submission to include information including the user's IP address, the date/time of submission, the user's email, and more. Your notification emails can even include values from the completed form.
To add tokens to a notification email, in the Body field, enter tokens from the Token values section. For example, if you want the notification email to include all of the visitor's webform results, include the %email_values
in the Body field.
Note: Several tokens include a key
, which allows you to obtain token information from a field on a webform. Each field on a webform has a Machine name, which is displayed under the Label field in Field settings > Properties.
For example, if you want to display the formatted field label and value for a specific webform field, use the %email[key]
token, and replace key
with the field's machine name (example, %email[new_1334599733011]
).
The THEMING.txt file included with the module package has guidelines for theming with instructions on how to customize submitted e-mails, confirmation pages, and the display of the form itself.