Changeset 1853
- Timestamp:
- 01/28/08 17:15:30 (6 months ago)
- Files:
-
- trunk/modules/forge/libraries/Forge.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/modules/forge/libraries/Forge.php
r1594 r1853 19 19 public $hidden = array(); 20 20 21 public function __construct($action = '', $title = '', $method = NULL, $ class = 'form')21 public function __construct($action = '', $title = '', $method = NULL, $attr = array()) 22 22 { 23 23 // Set form attributes … … 27 27 // Set template variables 28 28 $this->template['title'] = $title; 29 $this->template['class'] = $class; 29 30 // Empty attributes sets the class to "form" 31 empty($attr) and $attr = array('class' => 'form'); 32 33 // String attributes is the class name 34 is_string($attr) and $attr = array('class' => $attr); 35 36 // Extend the template with the attributes 37 $this->template += $attr; 30 38 } 31 39
