|
|
Drupal example source code file (webform-form.tpl.php)
The webform-form.tpl.php Drupal example source code<?php /** * @file * Customize the display of a complete webform. * * This file may be renamed "webform-form-[nid].tpl.php" to target a specific * webform on your site. Or you can leave it "webform-form.tpl.php" to affect * all webforms on your site. * * Available variables: * - $form: The complete form array. * - $nid: The node ID of the Webform. * * The $form array contains two main pieces: * - $form['submitted']: The main content of the user-created form. * - $form['details']: Internal information stored by Webform. */ ?> <?php // If editing or viewing submissions, display the navigation at the top. if (isset($form['submission_info']) || isset($form['navigation'])) { print drupal_render($form['navigation']); print drupal_render($form['submission_info']); } // Print out the main part of the form. // Feel free to break this up and move the pieces within the array. print drupal_render($form['submitted']); // Always print out the entire $form. This renders the remaining pieces of the // form that haven't yet been rendered above. print drupal_render_children($form); // Print out the navigation again at the bottom. if (isset($form['submission_info']) || isset($form['navigation'])) { unset($form['navigation']['#printed']); print drupal_render($form['navigation']); } Other Drupal examples (source code examples)Here is a short list of links related to this Drupal webform-form.tpl.php source code file: |
"Drupal" is a registered trademark of Dries Buytaert.
my drupal tutorials and examples
Copyright
1998-2016 Alvin Alexander, alvinalexander.com
All Rights Reserved.
Beginning in 2016, a portion of the proceeds from pages under the '/drupal-code-examples/' URI will be donated to charity.