Nette\Forms\Controls\ChoiceControl::getValue PHP 메소드

getValue() 공개 메소드

Returns selected key.
public getValue ( ) : string | integer
리턴 string | integer
    public function getValue()
    {
        return array_key_exists($this->value, $this->items) ? $this->value : NULL;
    }

Usage Example

예제 #1
0
 /**
  * Returns selected radio value.
  * @return mixed
  */
 public function getValue($raw = FALSE)
 {
     if ($raw) {
         trigger_error(__METHOD__ . '(TRUE) is deprecated; use getRawValue() instead.', E_USER_DEPRECATED);
         return $this->getRawValue();
     }
     return parent::getValue();
 }
All Usage Examples Of Nette\Forms\Controls\ChoiceControl::getValue