framework/widgets/InputWidget.php
protected function renderInputHtml($type)
    {
        if ($this->hasModel()) {
            return Html::activeInput($type, $this->model, $this->attribute, $this->options);
        }
        return Html::input($type, $this->name, $this->value, $this->options);
    }
protected function renderInputHtml($type)
    {
        if ($this->hasModel()) {
            return Html::activeInput($type, $this->model, $this->attribute, $this->options);
        }
        return Html::input($type, $this->name, $this->value, $this->options);
    }
Render a HTML input tag.

This will call [[Html::activeInput()]] if the input widget is [[hasModel()|tied to a model]],
or [[Html::input()]] if not.

@param string $type the type of the input to create.
@return string the HTML of the input field.
@since 2.0.13
@see Html::activeInput()
@see Html::input()