Example #1
0
 public function getAttributes()
 {
     $attributes = array_merge(parent::getAttributes(), array('data-sitekey' => $this->siteKey));
     unset($attributes['value']);
     unset($attributes['name']);
     return $attributes;
 }
Example #2
0
 public function getAttributes()
 {
     $attributes = parent::getAttributes();
     if ($this->isMultipleAllowed) {
         $attributes['multiple'] = 'multiple';
     }
     return $attributes;
 }
Example #3
0
 public function getAttributes()
 {
     $attrs = array('type' => 'checkbox', 'value' => self::ON);
     if ($this->isChecked()) {
         $attrs[self::CHECKED] = self::CHECKED;
     }
     return array_merge(parent::getAttributes(), $attrs);
 }
Example #4
0
 public function getAttributes()
 {
     $att = array();
     if (!empty($this->onEnter)) {
         $att['data-input-action-on-enter'] = $this->onEnter;
     }
     if ($this->mask !== null) {
         $att['data-input-mask'] = $this->mask;
     }
     return array_merge(parent::getAttributes(), $att);
 }
Example #5
0
 /**
  * {@inheritDoc}
  */
 public function getAttributes()
 {
     return array_merge(parent::getAttributes(), array('id' => $this->getId(), 'name' => $this->getName(), 'value' => $this->getDisplayedData(), 'disabled' => $this->isDisabled(), 'type' => $this->getOption('type')));
 }
Example #6
0
 public function getAttributes()
 {
     return array_merge(parent::getAttributes(), array('placeholder' => $this->label));
 }
Example #7
0
 /**
  * {@inheritDoc}
  */
 public function getAttributes()
 {
     return array_merge(parent::getAttributes(), array('id' => $this->getId(), 'name' => $this->getName(), 'rows' => 4, 'cols' => 30));
 }
Example #8
0
 protected static function renderButtonInput(Field $field)
 {
     return sprintf('<button type="%s" name="%s" value="%s" %s>%s</button>', $field->getType(), $field->getName(), $field->getValue(), $field->getAttributes(), $field->getLabel());
 }
Example #9
0
 public function getAttributes()
 {
     return array_merge(parent::getAttributes(), ["type" => "hidden"]);
 }