TbHtml::activeDateField PHP Method

activeDateField() public static method

Generates a date field input for a model attribute.
See also: self::activeTextInputField
public static activeDateField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.
    public static function activeDateField($model, $attribute, $htmlOptions = array())
    {
        return self::activeTextInputField('date', $model, $attribute, $htmlOptions);
    }

Usage Example

 /**
  * Renders a date field for a model attribute.
  * @param CModel $model the data model.
  * @param string $attribute the attribute.
  * @param array $htmlOptions additional HTML attributes.
  * @return string the generated input field.
  */
 public function dateField($model, $attribute, $htmlOptions = array())
 {
     return TbHtml::activeDateField($model, $attribute, $htmlOptions);
 }
All Usage Examples Of TbHtml::activeDateField
TbHtml