Community Documentation

Webform in a block

Last updated February 20, 2012. Created by peterx on February 20, 2012.
Log in to edit this page.

Webforms can be used in a block. You need the latest version of Webform.

  1. Create your webform in a node.
  2. Edit the node.
  3. Select the Webform tab.
  4. Select the Forms settings tab.
  5. Select the Forms settings tab.
  6. Select Advanced settings.
  7. Switch on Available as block.
  8. Save configuration.

Your webform is now available both as a content node and a block. You can hide the node or use it however you want. Look in the blocks list for the block. If you named your webform Example form, the block will be named Webform: Example form.

The block gives you the following choices.
Display mode

  • Form only
  • Full node
  • Teaser

Form only displays only the form. The title will be the block title.

Full node displays only the block title then the node title then the node body then the webform. Use this when you want text before or after the form. Remember to switch off either the block title or the node title.

I have not tried Teaser.

About this page

Audience
Developers and coders, Site administrators, Themers

Site Building Guide

Drupal’s online documentation is © 2000-2012 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution-ShareAlike 2.0. PHP code is distributed under the GNU General Public License. Comments on documentation pages are used to improve content and then deleted.