Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function example_theme() {
- return array(
- 'deductible_form' => array(
- 'arguments' => array('form' => NULL),
- 'template' => 'example',
- 'render element' => 'form',
- ),
- );
- }
- function deductible_form($form, &$form_state, $var1, $var2) {
- $form['#theme'] = 'deductible_form';
- $form['#var1'] = $var1;
- $form['#var2'] = $var2;
- // etc...
- return $form;
- }
- function theme_deductible_form($vars) {
- $form = $vars['form'];
- $var1 = $form['#var1'];
- $var2 = $form['#var2'];
- // Render the form
- }
- $form = drupal_get_form('deductible_form', $var1, $var2);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement