public function __construct($type = self::TEXT, $name = null, $value = null)
 {
     $this->_tag = 'input';
     parent::__construct();
     $this->_unpaired = true;
     if (!array_key_exists($type, self::$_types)) {
         throw new HTML_Input_Exception('Invalid input type');
     }
     $this->_attributes->register('type', self::$_types[$type]);
     $this->_attributes->register('name', $name);
     $this->_attributes->register('value', $value);
     $this->_attributes->register('checked');
     $this->_attributes->register('disabled');
     $this->_attributes->register('readonly');
     $this->_attributes->register('size');
     $this->_attributes->register('maxlength');
     $this->_attributes->register('src');
     $this->_attributes->register('alt');
     $this->_attributes->register('usemap');
     $this->_attributes->register('tabindex');
     $this->_attributes->register('accesskey');
     $this->_events->register('onfocus');
     $this->_events->register('onblur');
     $this->_events->register('onselect');
     $this->_events->register('onchange');
     $this->_events->register('accept');
 }
 public function __construct($rel = null, $type = null, $href = null)
 {
     $this->_tag = 'link';
     parent::__construct();
     $this->_unpaired = true;
     $this->_attributes->register('charset');
     $this->_attributes->register('href', $href);
     $this->_attributes->register('hreflang');
     $this->_attributes->register('type', $type);
     $this->_attributes->register('rel', $rel);
     $this->_attributes->register('rev');
     $this->_attributes->register('media');
 }
 public function __construct($src = null, $alt = null)
 {
     $this->_tag = 'img';
     parent::__construct();
     $this->_unpaired = true;
     $this->_attributes->register('src', $src);
     $this->_attributes->register('alt', $alt);
     $this->_attributes->register('longdesc');
     $this->_attributes->register('name');
     $this->_attributes->register('height');
     $this->_attributes->register('width');
     $this->_attributes->register('usemap');
     $this->_attributes->register('ismap');
 }
 public function __construct($id = null, $class_name = null)
 {
     $this->_tag = 'col';
     parent::__construct();
     $this->_unpaired = true;
     $this->_attributes->register('span');
     $this->_attributes->register('width');
     $this->_attributes->register('align');
     $this->_attributes->register('char');
     $this->_attributes->register('charoff');
     $this->_attributes->register('valign');
     if ($id !== null) {
         $this->id = $id;
     }
     if ($class_name !== null) {
         $this->class = $class_name;
     }
 }
 public function set($name, $value)
 {
     switch ($name) {
         case 'case':
         case 'view':
             $this->_view_case = $value;
             break;
         case 'vo':
             throw new Readonly_Variable_Exception($name);
         case 'content':
             $this->_content = $value;
             break;
         default:
             try {
                 parent::set($name, $value);
             } catch (HTML_No_Such_Element_Attribute_Exception $e) {
                 $this->_attributes->register($name, $value);
             }
     }
 }
 public function __construct()
 {
     $this->_tag = 'hr';
     parent::__construct();
     $this->_unpaired = true;
 }
 public function getElementsBy($property, $value)
 {
     $elems_a = parent::getElementsBy($property, $value);
     foreach ($this->_elements as $element) {
         $sub_elems_a = $element->getElementsBy($property, $value);
         foreach ($sub_elems_a as $match) {
             $elems_a[] = $match;
         }
     }
     return $elems_a;
 }