setValue() public method

Sets control's value.
public setValue ( $value ) : void
return void
Exemplo n.º 1
0
 /**
  * Is a control's value float number?
  * @return bool
  */
 public static function validateFloat(IControl $control)
 {
     $value = str_replace(array(' ', ','), array('', '.'), $control->getValue());
     if (Validators::isNumeric($value)) {
         $control->setValue((double) $value);
         return TRUE;
     }
     return FALSE;
 }