Orion PHP  0.11.12
The PHP5.3 framework
submit.php
Go to the documentation of this file.
00001 <?php
00002 namespace Orion\Core\Form;
00003 
00004 
00005 class Submit extends Field
00006 {
00007     public function __construct($bind='submit', $label='Submit')
00008     {
00009         $this->type = 'submit';
00010         $this->bind = $bind;
00011         $this->label = $label;
00012     }
00013 
00014     public function toHtml($XHTML=true)
00015     {
00016         if($XHTML)
00017             $tag = ' /';
00018         else
00019             $tag = '';
00020 
00021         return '<div class="form-row"><input name="'.$this->bind.'" type="submit" class="form-button form-submit" value="'.$this->label.'"'.$tag.'></div>';
00022     }
00023 }
00024 
00025 ?>