O'Reilly logo

Drupal 7 Webform Cookbook by Douglas Vernon Denny

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Adding a file component

The last thing we need our example Webform to handle is giving our registering speakers facility to upload their speaker profile. Typically, this is a file created by word-processing software and contains a picture of the speaker along with a brief biography.

How to do it...

  1. We will add a new File type component with the name Speaker profile and click on the Add button.
  2. In the Description textarea on the component edit page, we enter these guidelines: You may optionally upload your speaker profile here. File size is limited to 200KB and we accept most word processing software document types.
  3. In the Validation fieldset, we can select which file types (as denoted by their file extensions) we wish to permit for upload. The first ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required